D
Dica
i'm getting an error about 'the process cannot access the file becaise it is
being used by another process.' write after i've created a new file and try
to open it for writing with xmlTextWriter.
FileInfo oFileInfo = new FileInfo(STR_FILE_NAME);
bool bFileExists = oFileInfo.Exists;
if (!bFileExists)
{
oFileInfo.Create();
}
oFileInfo = null;
bankWriter = new XmlTextWriter(STR_FILE_NAME, null); // craps out here
i've tried setting oFileInfo to null hoping to release the resourece, but
it's still locked. anybody know how to get around this?
tks
being used by another process.' write after i've created a new file and try
to open it for writing with xmlTextWriter.
FileInfo oFileInfo = new FileInfo(STR_FILE_NAME);
bool bFileExists = oFileInfo.Exists;
if (!bFileExists)
{
oFileInfo.Create();
}
oFileInfo = null;
bankWriter = new XmlTextWriter(STR_FILE_NAME, null); // craps out here
i've tried setting oFileInfo to null hoping to release the resourece, but
it's still locked. anybody know how to get around this?
tks