Session.NewDesignFile() returns an int. What is the meaning of that value? What value does it return if the file is successfully opened?
Session.NewDesignFile()
int
Hi Jon Summers,
The .NET Session Manager DGN File operations wrap around the ISessionMgr C++ API and the 64-bit .NET int returns success or one of the error entries under the enum DgnPlatform::DgnFileStatus; like: DGNFILE_STATUS_Success, DGNOPEN_STATUS_AccessViolation, FILE_OPEN_STATUS_UnableToOpenSeed, DWGOPEN_STATUS_InvalidSeed, etc...HTH,Bob
Answer Verified By: Jon Summers
Robert Hook said:The .NET Session Manager DGN File operations wrap around the ISessionMgr C++ API
.NET NewDesignFile() doesn't appear to have a direct equivalent in C++. It looks like we need to use FindDesignFile() and then SwitchToNewFile() to open an existing DGN file with C++. There's an example in mgrTestTool.
NewDesignFile()
FindDesignFile()
SwitchToNewFile()
Regards, Jon Summers LA Solutions
Absolutely correct. NewDesignFile enables/disables levels of exceptions then calls: FindDesignFile and SwitchToNewFile().
Bob