The -debug command line parameter creates the msdebug.txt file in a 'Temp' folder. The 'Temp' folder location used varies by version of both application and Windows.
For CONNECT Edition the default location is the user's own 'Temp' folder defined by variable _USTN_LocalUserTempPath:
C:\Users\<username>\AppData\Local\Temp\Bentley\MicroStation\10.0.*
Once created an msdebug.txt file can be loaded into Bentley Configuration Explorer for review, this offers a more user friendly way to read the content.
Bentley Configuration Explorer is a powerful analysis and editing tool for configuration management and maintenance.
Press: Windows key + R
In the Run dialog type (or paste):
"C:\Program Files\Bentley\MicroStation CONNECT Edition\MicroStation\microstation.exe" -debug
The file will be saved to C:\Users\<username>\AppData\Local\Temp\Bentley\MicroStation\10.0.0\msdebug.txt and will open in Notepad (the application associated with the .txt file extension):
OR
Open a Command Prompt (Press the windows key and type 'cmd').
At the prompt type (or paste):
Navigate to the shortcut (for Windows 10 this will be "C:\ProgramData\Microsoft\Windows\Start Menu\Programs\MicroStation CONNECT Edition\MicroStation CONNECT Edition\MicroStation CONNECT Edition.lnk") and right-click > Properties.
On the Shortcut tab: add <space>-debug to the end of the MicroStation shortcut (in the Target: field)
On the General tab: rename the shortcut
For applications based on MicroStation the steps are similar, the paths used will be vary according to the application, e.g. for AECOsim Building Designer the debug command will be:
"C:\Program Files\Bentley\AECOsim CONNECT Edition\AECOsimBuildingDesigner\AECOsimBuildingDesigner.exe" -debug
The contents of msdebug.txt can be controlled by the addition of a switch at the end of the debug command when used in all three of the situations above.
-e.g.:
"C:\Program Files\Bentley\MicroStation CONNECT Edition\MicroStation\microstation.exe" -debug=n
There are two sections in the MSDebug.txt file. The first section contains a list of all the configuration files that are processed and what configuration variables were set in each file. Each configuration file that is processed has a starting point and an ending point identified as follows:
Processing macro file [C:\Bentley\Program\MicroStation\config\mslocal.cfg] . . . End of macro file [C:\Bentley\Program\MicroStation\config\mslocal.cfg]
Located in-between these two lines are all variables and their settings that get loaded from that particular configuration file:
Examples:
Processing macro file [d:\Bentley\Program\MicroStation\config\system\mslocal.cfg] (system): MS_SPELLINGLANGUAGE=AmericanEnglish [AmericanEnglish] (system): MS_HELPLOAD_LANGUAGE=en [en] End of macro file [d:\Bentley\Program\MicroStation\config\system\mslocal.cfg]
Processing macro file [d:\Bentley\Program\MicroStation\config\appl\qvisgl.cfg] (appl): MS_GRAPHICSACCELERATOR=qvisgl [qvisgl] End of macro file [d:\BentleyProgram\MicroStation\config\appl\qvisgl.cfg]
It also indicates at what level the variable has been set (e.g. system, appl, user, site, project, or predefined).
The last section of the MSDebug.txt file is the Configuration Variable Summary. Here you will find the following:
A listing of all configuration variables At what level each variable was set The full path to the location of the files Whether or not the variable is locked or unlocked
The msdebug file can help you troubleshoot things like processor exception errors by helping you find where specific files are located. The steps for this procedure are listed below:
MS_USERPREF (this will tell you where your user preference file is located) MS_INITAPPS (this will tell you if any other programs are being initiated during startup) MS_SYMBRSRC (this will point you to the location where all the MicroStation resource files are located)MS_DGNAPPS (this will tell you what other programs are being launched with MicroStation)MS_DGNMACROS (this will tell you what macros are being launched with MicroStation)_USTN_UIPATH (this will tell you the location of any *.m0* files)
Be sure to search for all instances of the variables.
For MicroStation V8 XM Edition and later, the file is created in the directory specified by the MicroStation configuration variable MS_TMP.
For V8 2004 and earlier, it is created in the folder where "Start in:" is set to (in MicroStation's program icon Properties dialog), which is typically the same folder where the ustation.exe file is located.
NOTES:
1. From a DOS prompt in a Command Shell Window
Go to a Command prompt and change to the directory where ustation.exe is located and type the following command: ustation.exe -debug
Examples: For MicroStation V8i: C:\Program Files\Bentley\MicroStation\ustation.exe -debug*For MicroStation V8 XM: C:\Program Files\Bentley\MicroStation\ustation.exe -debug*For MicroStation V8: c:\Program Files\Bentley\Program\Microstation\ustation.exe -debugFor MicroStation/J: c:\bentley\program\microstation\ustation.exe -debugFor MicroStation 95\SE: c:\win32app\ustation\ustation.exe -debug
2. From MicroStation's shortcut icon
Append <space>-debug to the end of the MicroStation shortcut (in the Target: field).
Examples: For MicroStation V8i: C:\Program Files\Bentley\MicroStation\ustation.exe -debug*For MicroStation V8: Target: c:\Program Files\Bentley\Program\Microstation\ustation.exe -debug*For MicroStation/J: Target: c:\bentley\program\microstation\ustation.exe -debugFor MicroStation 95\SE: Target: c:\win32app\ustation\ustation.exe -debugSave the changes and then double click the icon.NOTE: Remember to remove this change after creating the MSDebug.txt file.
3. From Windows "Run"
Choose Start > RunType the path to the ustation.exe file NOTE: If the path contains spaces, you must use quotes around the path
Examples: For MicroStation V8i: C:\Program Files\Bentley\MicroStation\ustation.exe -debug*For MicroStation V8: "c:\Program Files\Bentley\Program\Microstation\ustation.exe" -debug*For MicroStation/J: c:\Bentley\Program\MicroStation\Ustation.exe -debugFor MicroStation 95\SE: c:\win32app\ustation\ustation.exe -debug Click OK.
*NOTE: The location for ustation.exe for MicroStation V8i will be found at:C:\Program Files (x86)\Bentley\Program\MicroStation\ on 64-bit operating systems such as Vista and Windows 7.
You should get a DOS window that says "Debugging output saved to [msdebug.txt]".Hit the Enter keyLocate the msdebug.txt file in the appropriate directory.
To create a msdebug file in the MicroStation CONNECT Edition, see:https://communities.bentley.com/products/microstation/w/microstation__wiki/23926.export-configuration-variable-values-to-a-text-file
How to setup MicroStation logging with ProjectWise Explorer Integration
Bentley LEARN Server
Deutsch