This article can help anyone who is interested in learning how to setup shared workspaces in MicroStation and the Building Engineering products Architecture for MicroStation TriForma and Structural for MicroStation TriForma. Although workspaces can be configured many different ways, the purpose of this article is to explain a practical method of reconfiguring your workspace so that root paths may be placed in a central location, rather then under the bentley/workspace directory. For the purpose of simplicity, the bentley/workspace directory and the workspace root variable will be modified as an example.
MicroStation has always had the capability to network its data files, but with the release of MicroStation/J the Workspace directory and its related _ustn_workspaceroot variable, the location of the Workspace directory could hinge on one variable. In addition, variables referencing the workspace directory could be directed by the variable _ustn_workspaceroot. For example:
_USTN_SITE = $(_USTN_WORKSPACEROOT)standards/
This is not a complex topic. Many understood referencing of variables and centralizing the workspace long before MicroStation/J did it out of the box. Many want to know if there is a best way to do this. You could, of course, just edit the msconfig.cfg file to point to the shared workspace, but it is usually best to avoid editing any file under the program directory or any file delivered by MicroStation.
A preferred method would be to create and specify a configuration file on startup that modifies the configuration of MicroStation variables. Direct the local configuration file-such as mslocal.cfg or Bentley Structural's stflocal.cfg-to include this startup configuration file. Place the local configuration file and the startup configuration file on the network where you have copied your workspace. Create a shortcut that calls the local configuration file on the network. The procedure for this setup is as follows:
1. Copy the entire bentley/workspace directory to your network. The location of this network drive must be accessible to all the users on your project team.
2. Copy the delivered local configuration file to the workspace directory on the network drive and change its name to something like "yourfirmname_local.cfg." The local configuration file you copy should be the one used to start up your application; atflocal.cfg for Architectural, stflocal.cfg for Structural, or mslocal.cfg for MicroStation V8. Add the preprocessor directive %include and point it to the name of the startup config file. You can read more about preprocessor directives in the MicroStation Administrator guide. The statement in the local configuration file would look something like this:
# Include Firm Startup Config
3. In the same location, create a file "yourfirmname_startup.cfg." This file will control where various parts of the workspaces are located. You can use the below as a template, but edit the locations as appropriate to your system.
_USTN_WORKSPACEROOT = N:/Wspace/
_USTN_PROJECTSROOT = $(_USTN_WORKSPACEROOT)projects/")
4. Create a shortcut on your desktop to startup MicroStation and point to the "yourfirmname_local.cfg" file on the network. To point to the local configuration file use the command line option -wc. Building Engineering products like Architecture for MicroStation TriForma and Structural for MicroStation TriForma have always pointed to a local configuration file in the shortcut to manage their configuration. You could do the same with your own custom shortcut and a command line option. See TechNote 7102 for more information on command line options. The Target of the shortcut would look something like this:
"BLOCKED SCRIPTvoid(null);" -wcN:\Wspace\Mynetwork_mslocal.cfg
Use this shortcut to access the network workspace.
Here are a few notes on the changes that make this possible in Architecture for MicroStation TriForma and Structural for MicroStation TriForma V8:
All Architecture and Structural variables are now loaded at the Application level instead of the User level, similar to MicroStation.All required interface files are being loaded as "Corporate Interfaces."In MicroStation V8 there are example projects delivered. You can use these Project Configuration Files (*.pcf) as a guide to creating your own.Make sure that the folder where your User directory is located contains an "examples.ucf," as this is the default chosen by MicroStation.
The steps to create the configuration are relatively simple, but to demonstrate the procedure, a VBA app called the "Shared Workspace Creator" is available to walk you through the creation of your custom configuration. There are four steps involved in setting up and connecting to this network workspace:
Step 1: Locate the Network Workspace Root directory.
Step 2: Select a Local Configuration file to be copied to root directory.
Step 3: Create a Startup Configuration file on the root directory.
Step 4: Create Shortcut to startup MicroStation with this Network Workspace.
To use the VBA, download it and place it in your local Workspace\system\vba directory, then key in "VBA run [SWCreator] main.Startup." This VBA uses the VBA examples DirectoryBrowser.mvba and WinFileDialog.mvba available in the VBA examples found on MicroStation on the Web. To create the desktop shortcuts the Windows Scripting Host Object Model was used.
In conclusion, the key goal of this exercise was to make it easy for a project team to centralize all dataset information (fonts, seed files, cells, TriForma Parts, components, frames, etc.) in a shared location on a server.