18
MicroStation Workspaces for LADPW Archway Systems, Inc. Mike Lazear

Archway Systems, Inc. Mike Lazear. Profile SELECTservices Learning (LEARNserver) Communities (BeCommunities) Video (BeConnected) Events Bentley Student

Embed Size (px)

Citation preview

Page 1: Archway Systems, Inc. Mike Lazear. Profile SELECTservices Learning (LEARNserver) Communities (BeCommunities) Video (BeConnected) Events Bentley Student

MicroStation Workspacesfor LADPWArchway Systems, Inc.

Mike Lazear

Page 2: Archway Systems, Inc. Mike Lazear. Profile SELECTservices Learning (LEARNserver) Communities (BeCommunities) Video (BeConnected) Events Bentley Student

Plugging in to the Bentley world

• Profile• SELECTservices• Learning (LEARNserver)• Communities (BeCommunities)• Video (BeConnected)• Events• Bentley Student Center (YouTube channel)• Bentley LEARNing Conference free on-demand

recordings

• How to learn Bentley Products – YouTube video

Page 3: Archway Systems, Inc. Mike Lazear. Profile SELECTservices Learning (LEARNserver) Communities (BeCommunities) Video (BeConnected) Events Bentley Student

Configuration Tools• Bentley Configuration Explorer

o Shows all configuration variables and their valueso Free from Bentley’s web site – iWare app for PCo http://

www.bentley.com/en-US/Free+Software/Bentley+Configuration+Explorer.htm

• Notepad++o Free Notepad type editor that has many excellent featureso http://notepad-plus-plus.org/o Use Settings > Style Configurator to add ucf, pcf, cfg to ini file

entry

• Windows Explorer (part of Windows, Windows-E to launch)o Add path to Workspace and to MicroStation V8i to Favorites

Page 4: Archway Systems, Inc. Mike Lazear. Profile SELECTservices Learning (LEARNserver) Communities (BeCommunities) Video (BeConnected) Events Bentley Student

Configuration Files• MicroStation uses Configuration files to control how it runs• Configuration files contain configuration variables• The configuration files are searched for in a specific order

• Examples:• .ucf – User Configuration file

o Typically located in …\WorkSpace\Userso Editable text.

• .pcf – Project Configuration fileo Typically located in …\WorkSpace\Projectso Editable text.

• .cfg – General Configuration file

o Editable text.

• .upf – User Preferences file. o Binary file. Edit by changing settings in Workspace > Preferences.o Storage depends on Windows release but stored within User’s folder (see MS_USERPREF)

See Workspace > About Workspace for location of current config files being used

Page 5: Archway Systems, Inc. Mike Lazear. Profile SELECTservices Learning (LEARNserver) Communities (BeCommunities) Video (BeConnected) Events Bentley Student

Configuration Variable Types

• Program configuration path variableso Tells MicroStation where to find .exe, .dll as well as other

file typeso Typically will start with a c:\Program Files or c:\Program

Files (x86)

• Workspace (i.e. Data) configuration path variableso Tells MicroStation where to find resource files like dgnlib,

rsc, mvbao Typically will start with a c:\ProgramData path

• Value Configuration variableso Actual values used to tell MicroStationo Ex. 0, 1, 08.11.09.357, FALSE, markup

Page 6: Archway Systems, Inc. Mike Lazear. Profile SELECTservices Learning (LEARNserver) Communities (BeCommunities) Video (BeConnected) Events Bentley Student

Configuration Levels• 0) System Level• 1) Application Level• 2) Site Level• 3) Project Level• 4) User Level

Processed in the above order, Application overrides System, Site overrides Application, Project overrides Site and User overrides Projects. Thus User Level takes priority over all other levels unless locked at an earlier level.

Page 7: Archway Systems, Inc. Mike Lazear. Profile SELECTservices Learning (LEARNserver) Communities (BeCommunities) Video (BeConnected) Events Bentley Student

Who sets these Config variables?

• 0) System Levelo Set by Bentley Developers – avoid changing

• 1) Application Levelo Set by Add-on Application Developers – avoid changing

• 2) Site Levelo Set on behalf of corporate/site management by System/IT Manager

• 3) Project Levelo Set by, or on behalf of, the Project Manager

• 4) User Levelo Set by, or on behalf of, the User

These are typical guidelines and not hard & fast rules

Page 8: Archway Systems, Inc. Mike Lazear. Profile SELECTservices Learning (LEARNserver) Communities (BeCommunities) Video (BeConnected) Events Bentley Student

Configuration Levels – System Level

• 0) System Levelo …\Program Files\Bentley\Microstation V8i (SELECTseries)\MicroStation\

config

o mslocal.cfg – location of MicroStation and includes the next two

o msdir.cfg – location of WorkSpaceo Msconfig.cfg – controls the reading of all other config

files and levels

• 1) Application Level• 2) Site Level• 3) Project Level• 4) User Level

Page 9: Archway Systems, Inc. Mike Lazear. Profile SELECTservices Learning (LEARNserver) Communities (BeCommunities) Video (BeConnected) Events Bentley Student

Configuration Levels – Application Level

• 0) System Level• 1) Application Level

o …\config\appl (this is one folder below the System Level config files)

o Set by add-on applications (ex. clashDetection, ProjectWise)

o File names ex.: ClashDetection.cfg, PW.cfg, ComponentView.cfg

o Could redefine system level config variables but more likely to add new config variables or add additional paths to existing

• 2) Site Level• 3) Project Level• 4) User Level

Page 10: Archway Systems, Inc. Mike Lazear. Profile SELECTservices Learning (LEARNserver) Communities (BeCommunities) Video (BeConnected) Events Bentley Student

Configuration Levels – Site Level

• 0) System Level• 1) Application Level• 2) Site Level

o …\Workspace\Standardso Contains config customization for the company or siteo By default all .cfg (any name) in the Standards folder will

be read• See use of _USTN_SITE in MSCONFIG.CFG

o Many folders with Standards that include dgnlib, cells, macros (.mvba), plot configuration files (pltcfg), seeds, and more

• 3) Project Level• 4) User Level

Page 11: Archway Systems, Inc. Mike Lazear. Profile SELECTservices Learning (LEARNserver) Communities (BeCommunities) Video (BeConnected) Events Bentley Student

Configuration Levels – Project Level

• 0) System Level• 1) Application Level• 2) Site Level• 3) Project Level

o …\Workspace\Projectso Read AFTER User Level but processed BEFORE User Levelo Contains config customization for the project in .pcf fileo Many folders within the named project folder with Projects

that include dgnlib, cells, macros (.mvba), plot configuration files (pltcfg), seeds, and more

o Ex. …\Projects\Building\dgnlib\Levels.dgnlib

• 4) User Level

Page 12: Archway Systems, Inc. Mike Lazear. Profile SELECTservices Learning (LEARNserver) Communities (BeCommunities) Video (BeConnected) Events Bentley Student

Configuration Levels – User Level

• 0) System Level• 1) Application Level• 2) Site Level• 3) Project Level• 4) User Level

o …\Workspace\Userso Is read BEFORE Project Level but processed AFTER

Project Levelo Determines which Project configuration file is processed,

which is the reason it is read before the Project Level.o Contains config customization for the user in .ucf file

Page 13: Archway Systems, Inc. Mike Lazear. Profile SELECTservices Learning (LEARNserver) Communities (BeCommunities) Video (BeConnected) Events Bentley Student

Key root configuration variablesUse Bentley Configuration Explorer to view values

• _ROOTDIRo C:\Program Files (x86)\Bentley\MicroStation V8i (SELECTseries)\

MicroStation\

• MSDIRo ${MS} or ${_ROOTDIR}/o C:\Program Files (x86)\Bentley\MicroStation V8i (SELECTseries)\MicroStation\

• _USTN_BENTLEYROOTo ${parentdevdir {MSDIR}}o C:\Program Files (x86)\Bentley\MicroStation V8i (SELECTseries)\

• __USTN_WORKSPACEROOTo _USTN_WORKSPACEROOT : ${_USTN_INSTALLED_WORKSPACEROOT}o C:\ProgramData\Bentley\MicroStation V8i (SELECTseries)\WorkSpace\

• _USTN_HOMEROOT

Page 14: Archway Systems, Inc. Mike Lazear. Profile SELECTservices Learning (LEARNserver) Communities (BeCommunities) Video (BeConnected) Events Bentley Student

Variable definition references

• $(VARIABLEREF) = Expand VARIABLEREF when this variable is used.

• ${VARIABLEREF} = Expand to current value of VARIABLEREF and does not change.

• Configuration variables use / instead of \ internally changed to \ when needed

• All Path variables (should) end with /

Page 15: Archway Systems, Inc. Mike Lazear. Profile SELECTservices Learning (LEARNserver) Communities (BeCommunities) Video (BeConnected) Events Bentley Student

Variable references examples

• MS_DIR = “C:/Stuff/”• MS_DEF = $(MS_DIR)• MS_SEEDFILES = ${MS_DIR}

• > All variables if accessed at this point equal “C:/Stuff/”

• If later we set MS_DIR = “D:/Stuff/”• If variables accessed at this point what would the

values be?o MS_DIR = “D:/Stuff/”o MS_DEF = “D:/Stuff/”o MS_SEEDFILES = “C:/Stuff/

Page 16: Archway Systems, Inc. Mike Lazear. Profile SELECTservices Learning (LEARNserver) Communities (BeCommunities) Video (BeConnected) Events Bentley Student

Workspace Operators• = Assign “new_value” to “VARIABLENAME”• : Assign “new_value” to “VARIABLENAME”

only if that variable does not already exist (not already set)

• > Append directory or file lists defined by “new_value” to a variable definition that defines a path.

• < Prepend directory or file list defined by “new_value” to the beginning of a variable defintion that defines a path.

• + Append “new_value” to current value of “VARIABLENAME”. Uses a space as a separator.

(rarely used)

Page 17: Archway Systems, Inc. Mike Lazear. Profile SELECTservices Learning (LEARNserver) Communities (BeCommunities) Video (BeConnected) Events Bentley Student

Preprocessor directives• %include <filename> Includes another config file• %if <expression> Execute following lines if

expression is true• %else Execute following lines if original

expression on %if was false

• %endif End of conditional block• %error <string> Print “string” and exit

MicroStation• %lock <varName> Locks the

configuration variable• %level Set the level of processing

Page 18: Archway Systems, Inc. Mike Lazear. Profile SELECTservices Learning (LEARNserver) Communities (BeCommunities) Video (BeConnected) Events Bentley Student

Configuration Variable List

• To get a listing of all MicroStation’s Configuration Variables o load the cfgvars.ma (mdl app)o Utilities > MDL Applications. Click the Browse button and open the

“asneeded” folder. Load cfgvars.ma.o Utilities > key-in type the following:

• mdl load cfgvars printCfgVarResource (case sensitive)o In the MicroStation root directory (within Program Files) search for

cfgvars.txt and cfglong.txt. These files list the configuration variables.

• Setting _USTN_DISPLAYALLCFGVARS to 1 Workspace > Configuration will show the hidden system Configuration variables.

• https://communities.bentley.com/products/microstation/w/microstation__wiki/microstation-v8i-variables.aspx