Copying Model and File Locations
A model version or a file version stored in a Model Manager database can be uniquely identified using an item version location. This is a text string URI that you can copy to your computer’s clipboard by right-clicking an item version in the Model Manager workspace and selecting Copy Location ().
Using Copy Location With Models
You can use Copy Location () to open a specific model version in another COMSOL Multiphysics program session:
1
A text string URI that uniquely identifies the model version is copied to your computer’s clipboard.
2
From the File menu in another COMSOL Multiphysics program session, select Open From ().
3
Select the Clipboard menu option in the Open window. The model version is shown as a single option in the list on the right. Click Open ().
An identical Clipboard menu option also appears in the Select Model window when you have copied a model version location — see Inserting Parts and Other Model Contents from Databases.
You can also use Copy Location () to change the source of a loaded geometry part found in the model opened in the COMSOL Desktop, as long as the old part and the new part use the same node tag:
1
2
3
In the File section of the Settings window, click the Location menu () and select Paste Location ().
4
Click Reload () to load the geometry part into the model.
Using the Copy Location action from The Versions Window is a good alternative to finding the version via the Select Model window when you want to reference an older version of a geometry part.
The location text string URI can also be used to access the model version via method code using the Model Manager API. While the URI itself has a rather opaque format, you can recognize the URI by it always starting with dbmodel:///.
Using Copy Location With Files
For a file version, you can use Copy Location () to reference the file version from an input or output setting in the model opened in the COMSOL Desktop:
1
Right-click a file version in the Model Manager workspace and select Copy Location (). If the file version is a fileset, you will be asked to select which file resource whose file location you want to copy via the Select File from Fileset dialog box. Select a row in the table and click OK.
A text string URI that uniquely identifies the file resource is copied to your computer’s clipboard.
2
3
The filename of the file resource, and the database the file belongs to, is displayed as a label in the Filename field. Depending on the input or output nature of the setting, you can now import or export data from or to the file in the database.
Using the Copy Location action from The Versions Window is a good alternative to finding the version via the Select File window when you want to reference an older version of a data file.
The location text string URI can also be used to access the file version via method code using the Model Manager API. While the URI itself has a rather opaque format, you can recognize the URI by it always starting with dbfile:///.