Select from multiple guixt.sjs files.
The switchto command is used principally to map a user's individual guixt.sjs file to a main guixt.sjs file hosted on a server. This objective is useful for enabling users to see configuration changes without the necessity of making changes to a local profile. There are two possible syntaxes, depending if a single statement or an array containing multiple locations is to be used. The array syntax is as follows:
| Item/Syntax | Description |
|---|---|
| switchto = ["\\\\company.com\\guixt\\guixt1.sjs"]; | Single Example |
| switchto = [ "\\\\customer.com\\GUIXT\\guixt1.sjs", "\\\\customer.com\\GUIXT\\guixt2.sjs", "\\\\customer.com\\GUIXT\\guixt3.sjs", ]; | Array example |
| switchto = [ "\\\\COMPUTER\\GUIXT\\guixt1.sjs", "\\\\COMPUTER\\GUIXT\\guixt2.sjs", "\\\\COMPUTER\\GUIXT\\guixt3.sjs", ]; | Array example with system names |
If no sjs file in the array is specified as being active WS will parse and select the first available location. If both a single statement and an array are contained within a given guixt.sjs file, the array will take precedence. The storage location can be one of the following:
When specifying a network share, it is important to make sure that each element is separated by two backslashes - Webscript has problems reading it otherwise. For the SAP Web Repository, the file location syntax must be written as follows:
"SAPWR:Z.Test.GUIXT.SJS"
The switchto command does not take any options.
Switchto enables recursive deployment. What this means is that if there are multiple guixt.sjs files and each one contains a switchto statement, the last valid file will be the one used.
For example, if the first guixt.sjs file resides on the local system and contains a switchto statement specifying two guixt files, the switchto command will parse the paths and proceed to the first valid file. In our example, this file would be 'C:\\text\guixt\\guixt1.sjs. However, within this new guixt.sjs file there is also a switchto command, listing three more directories. The first one proves to be invalid - perhaps it is missing a script directory or maybe the RFC user information is incorrectly defined. So the second guixt.sjs file is selected. In our example, this new guixt.sjs file is '\\\\netshare\\guixt\\guixt2.sjs'. The guixt.sjs file on netshare contains a valid script directory, so at that point, the switchto command ceases looking for additional guixt.sjs files. This process is illustrated in the following diagram:
