All,
We have a legacy MicroStation application which has been problem-free but which was recently tested running on MicroStation 10.15.00.74. The application runs as an INITAPP and never calls mdlSystem_enterGraphics. Upon calling mdlSystem_newDesignFile, the following error is displayed in the Text Window:
log4net:ERROR XmlHierarchyConfigurator: Cannot find Property [createpath] to set object on [log4net.Appender.RollingFileAppender]
Any idea what could cause this behavior and/or possible workarounds?
TIA
Steve
Steve Salata said:Upon calling mdlSystem_newDesignFile, the following error is displayed in the Text Window:
Does your code wait until file open completes? In v8, that was mdlSystem_setFunction(), which in CONNECT is type-safe SystemFunc_NewDesignFile.
mdlSystem_setFunction()
SystemFunc_NewDesignFile
Regards, Jon Summers LA Solutions
Hi Jon
Thanks for the good suggestion but the log4net error is displayed before the newFileDesign system callback function is even called.
The
mdlSystem_newDesignFile
Steve Salata said:We have a legacy MicroStation application which has been problem-free
On earlier versions (i.e. V8) of MicroStation or an earlier update of CONNECT?
Please post your MdlMain() function code.
MdlMain()
Not much to the main function code, but here it is:
extern "C" DLLEXPORT void MdlMain ( int argc, /* => Number of arguments passed in pargv */ WCharCP argv[] /* => Array of pointers to arguments */ ) { RscFileHandle rfHandle; /* resource file handle */ if (argc <= 2) { mdlOutput_printf(MSG_ERROR, L"ERROR: This program cannot be run interactively."); return; } mdlResource_openFile(&rfHandle, NULL, FALSE); SystemCallback::SetReloadProgramFunction (reloadProgram); SystemCallback::SetNewDesignFileFunction(newDesignFile); handleArgs(argc, argv); mdlSystem_closeDesignFile(); }
Steve Salata said:Not much to the main function code
Less to go wrong! What happens in handleArgs? Presumably, you're opening one or more DGN files for processing?
handleArgs
Yes, handleArgs opens/updates a series of design files. The log4net error appears on the first call to mdlSystem_newDesignFile but does not prevent successful processing of any design file.
mdl
System_newDesignFile
Perhaps Robert Hook can tell us the purpose of log4net?