![]() I would follow David's suggestion and try putting the script file on a local drive (like C:), as there may be problems with the way files are closed if you are using a network or USB drive to hold the file.Īlso, I don't think this is related to Lua somehow. Judging by the MFC code, it should have thrown an exception if the file failed to close.ĭoes this happen the first time you edit the file? Or the second time? Maybe the editor doesn't close the file, especially if you use a different editor. You can see that the file is indeed opened to deny writing, however the last line closes the file, so it should now be possible to write to it. close the file in case they try to modify it M_strScript.ReleaseBuffer (fileScript.GetLength ()) m_strScript now contains the entire script file CFile fileScript (m_strScriptFilename, CFile::modeRead | CFile::shareDenyWrite) Ĭhar * p = m_strScript.GetBuffer (fileScript.GetLength ()) įileScript.Read (p, fileScript.GetLength ())
0 Comments
Leave a Reply. |
AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |