When and how is BricsCAD initialized using root folders?
When BricsCAD starts up, the following three steps are performed (conditionally):
Step 1
ROAMABLEROOTFOLDER and LOCALROOTFOLDER in HKCU\Software\Bricsys\BricsCAD\V24x64\en_US\Settings are generated:
- ROAMABLEROOTFOLDER = value of AppData in key HKCU\\Software\\Microsoft\\Windows\\CurrentVersion\\Explorer\\Shell Folders + subfolders \Bricsys\BricsCAD\V24x64\en_US\
- LOCALROOTFOLDER = value of Local AppData in key HKCU\\Software\\Microsoft\\Windows\\CurrentVersion\\Explorer\\Shell Folders + subfolders \Bricsys\BricsCAD\V24x64\en_US\
Triggers step 1:
- LOCALROOTFOLDER: the setting is empty, the folder does not exist, the folder has no subfolders.
- ROAMABLEROOTFOLDER: the setting is empty, the folder does not exist, the folder has no subfolder called support or this subfolder contains no files.
Step 2
Files are copied from INSTALLFOLDER\UserDataCache to user folders:
- ("*.dwt") from userdatacache\templates to LOCALROOTFOLDER\templates
- ("*.*") from userdatacache\templates\en_US to LOCALROOTFOLDER\templates
- ("*.*") from userdatacache\plotstyles to ROAMABLEROOTFOLDER\plotstyles
- ("*.*") from userdatacache\plotconfig to ROAMABLEROOTFOLDER\plotconfig
- ("*.*") from userdatacache\support to ROAMABLEROOTFOLDER\support
- ("*.*") from userdatacache\support\en_US to ROAMABLEROOTFOLDER\support
Triggers step 2:
- Either LOCALROOTFOLDER or ROAMABLEROOTFOLDER setting was created in step 1.
- Setting VersionCustomizableFiles in HKCU\Software\Bricsys\BricsCAD\V24x64\en_US\Settings does not exist or has a value smaller than the value hard coded into the current running version of BricsCAD. (i.e. on a new installation or after an update).
Step 3
System paths, if empty, are initialized:
- PLOTSTYLEPATH = ROAMABLEROOTFOLDER\plotstyles
- PLOTCFGPATH = ROAMABLEROOTFOLDER\plotconfig
- SRCHPATH = ROAMABLEROOTFOLDER\support;INSTALLFOLDER\support;INSTALLFOLDER\Fonts;INSTALLFOLDER\Help\en_US
- TEMPLATEPATH = LOCALROOTFOLDER\templates
- DRAWINGPATH = MYDOCUMENTSFOLDER
- BLOCKSPATH = MYDOCUMENTSFOLDER
- RECENTPATH = MYDOCUMENTSFOLDER
- XLOADPATH = MYDOCUMENTSFOLDER
Triggers step 3:
This step is always performed. Empty paths are created.
TIPS to use ROAMABLEROOTFOLDER and LOCALROOTFOLDER
On standard installations, BricsCAD initializes these registry keys, and performs steps 1 - 3. To change this behavior, you can specify your own preferred folders by creating these keys in the registry:
ROAMABLEROOTFOLDER and LOCALROOTFOLDER in HKCU\Software\Bricsys\BricsCAD\V24x64\en_US\Settings.
If you make sure that the folders exist and that they have this folder structure:
- LOCALROOTFOLDER\templates
- ROAMABLEROOTFOLDER\plotstyles
- ROAMABLEROOTFOLDER\plotconfig
- ROAMABLEROOTFOLDER\support (not empty folder)
then BricsCAD initializes all paths automatically into these folders (see Step 3).
- ROAMABLEROOTFOLDER system variable: Stores the full path to the root folder where roamable files for the current user, such as menus and plotstyles, were installed.
- LOCALROOTFOLDER system variable: Stores the full path to the root folder where local files for the current user, such as templates, were installed.
- For version V1x,... replace V20 by V1x. For other languages, e.g. de_DE, replace en_US by de_DE.
- It is possible to override ROAMABLEROOTPREFIX with a new path. The new path will be accepted if the matching folder contains a subfolder support with at least one file in it, just as is the case with ROAMABLEROOTFOLDER. Otherwise, the path will be reset to the default.
- LOCALROOTPREFIX can also be overridden. The new path should contain at least one subfolder, otherwise the path is reset to default.