Preset and System Variables – Glossary

The System variables are listed in the Variables tab of the Publication Properties dialog. Opus provides the System variables, which are ready-to-use variables that already contain information. For example, the PUBLICATION_TIME variable contains the current time the user has been running the publication.

The System variables contain information about the system that it is currently working on and are constantly updated by Opus. Therefore, while you are developing your publication, the data contained in the variables is about your system; but when the user runs your publication it will be data about their system. For example, SYSTEM_DATE_FULL will show the full date for the machine on which the publication is running.

The System variables fall into one of the categories described below. Each of the System variables are then described in the rest of this section.

Note:
For a general description of the System variable type – see Types of Variables for more information.

Also, System variables cannot be deleted from the Variables tab in the Publication Properties dialog.

The Preset and System variables can be categorised as follows:

  1. Scoring information – these variables contain data when you have used the Scoring actions in your publication – see Introducing the Scoring Actions for more information. They are also used by the Question Object – see Introducing the Question Object for more information.

  2. Date and Time information – these variables contain information about the current date and time on the system, there are individual variables for month, day, hours, minutes, etc.

  3. System information – these variables contain information about the system the publication is currently running on, such as, the systems Colour Depth, Screen Resolution.

  4. System Folder information – these variables will work out the pathname to folders on the current system. For example, the pathname to the Windows Temp folder or Program Files. These are particularly useful as shortcut methods of adding pathnames but more importantly if your users work on different platforms (e.g. Windows 98, 2000 or XP), then the paths to folders is not the same – for example, the path to the Windows Temp folder on a Windows 95 system is not the same as on Windows XP.

  5. Publication information – these variables provide information about features within the publication itself, such as, how long the publication has been running, the current radio button selected in a group, and so on.

  6. eLearning and SCORM Support – there are a range of variables provided to compliment the data models in SCORM and for advanced use in checking communication with a SCORM Learning Management System.

  7. User Details – we have also included a set or readymade variables to handle commonly-used inputs such as username and trainer’s name.

The Scoring information:

  1. SCORE_VALUE – Calculates the total value of the allocated scores that have been answered correctly. For example, the user must answer 4 questions with scores allocated thus: Q1 = 1, Q2 = 3, Q3 = 5 and Q4 = 2. Only the first three answers are correct, so the score value would be 9. If all answers were correct, the score would have been 11.

  2. SCORE_VALUE_TOTAL – Calculates the total value of the allocated scores which have been answered, whether the user answer the question correctly or not. Using the example above (point 1), this variable would contain the value 11.

  3. SCORE_VALUE_PERCENT – Keeps track of the total value of available points as a percentage for a single question. It is not the total scored for all questions.

  4. SCORE_CORRECT – Use this to give you the number of questions which have been answered correctly, e.g. 5 out of 7 questions.

  5. SCORE_INCORRECT – Use this to give you the number of questions which have been answered incorrectly e.g. 2 out of 7 questions.

  6. SCORE_TOTAL – Calculates the number of questions the user has attempted to answer, whether that answer was correct or not. It is not their total score, which is stored in SCORE_VALUE. For example, if there are 10 questions, the user has attempted to answer 7 but only got 4 correct, the score total would be 7.

  7. SCORE_PERCENT – Calculates the percentage of questions which have been answered correctly, for example 6 correct answers out of 10 questions would produce a score of 60%, 6 out of 15 questions would be 40%.

  8. SCORE_TOTAL_POSSIBLE – User-defined variable in which to store the maximum possible score for the whole quiz irrespective of how many the user has answered. You need to add this value manually

  9. SCORE_CURRENT_POSSIBLE – User-defined variable to store the total possible score. It is calculated as SCORE_TOTAL_POSSIBLE less SCORE_VALUE_TOTAL

  10. SCORE_PASS_THRESHOLD – User-defined variable to store the score required to achieve a pass. This allows you to monitor the SCORE_CURRENT_POSSIBLE value against the Pass mark and force the user to recover the training until a pass level is maintained.

The Date and Time information:

  1. SYSTEM_TIME_YEAR – provides the current year according to the system setup e.g. 1999. This is shown as a number.

  2. SYSTEM_TIME_MONTH – provides the month e.g. May. This is shown as a word, not a number.

  3. SYSTEM_TIME_DATE – provides the date e.g. 02. This is shown as a number.

  4. SYSTEM_TIME_DAY – provides the day of the week, e.g. Fri. This is shown as a three-letter word.

  5. SYSTEM_TIME_HOUR – Holds the hour of the day in twenty-four hour format, e.g. 23 for 11pm. This is shown as a number.

  6. SYSTEM_TIME_MINUTE – provides the minute of the hour, e.g. 39. This is shown as a number.

  7. SYSTEM_TIME_SECOND – provides the second of the minute, e.g. 45. This is shown as a number.

  8. SYSTEM_TIME_12HOUR – Holds the hour in twelve-hour format, e.g. 11 for 11pm. This is shown as a number.

  9. SYSTEM_TIME_AMPM – provides an AM or PM response depending on current hour, e.g. AM for 9am. This is shown as a two-letter word.

  10. SYSTEM_DATE_FULL – provides the current date in full, formatted as 01 January 2001.

Note:
To format the time appropriately and to include leading zeros and set decimal places – see Format Variable to String action for more information.

The System Information:

  1. SYSTEM_USERNAME – provides the name of the user logged onto the Windows system e.g. Administrator.

  2. SYSTEM_CD_DRIVE – provides the drive letter of the first CD-Rom drive on the system e.g.: D: – this is the normal drive letter for a CD drive.

  3. SYSTEM_COLOUR_DEPTH – provides the colour depth of the current screen on the system e.g. 32 – the colour depth set to 32bits.

  4. SYSTEM_SCREEN_RES_X – provides the current screen resolution width setting for the system e.g. 1024 – meaning 1024 pixels across the screen.

  5. SYSTEM_SCREEN_RES_Y – provides the current screen resolution height setting for the system e.g. 768 – meaning 768 pixels down the screen.

  6. SYSTEM_OPERATING_SYS – provides the Windows platform for the system e.g. 2000 – meaning a Windows 2000 machine.

 The possible values for this variable are:

Value

Operating System

NT3

Windows NT 3.51

95

Windows 95

98

Windows 98

ME

Windows Me

NT4

Windows NT 4.0

2000

Windows 2000

XP

Windows XP

2003

Windows Server 2003

Vista

Vista

Windows 7

Windows 7

  1. SYSTEM_HAS_SOUND – provides an answer of true if the current system has a sound card installed and false if no sound card, e.g. true – will always provide a response of true or false.

The System Folder Information:

  1. SYSTEM_WINDIR – provides the directory where Windows is installed e.g. C:\WINNT – the pathname to the folder on Windows 2000 systems.

  2. SYSTEM_WINSYS_DIR – provides the location of the Windows’ System directory e.g. C:\WINNT\System32 – the pathname on Windows 2000 systems.

  3. SYSTEM_PUBLICATION_DIR – provides the location of the current Opus publication e.g. C:\Education\Tutorial\ – meaning the publication can be found in this folder.

Note:
Notice the backslash has already been added after the last folder in the path (i.e. after the Tutorial folder) in case you want to add files to this folder or create new sub folders after the current path.

  1. SYSTEM_PROGRAMS_DIR – provides the location of the standard Program Files directory e.g. C:\Program Files – this is the standard folder in which applications are installed on a user’s system.

  2. SYSTEM_PROGRAMDATA_DIR – provides the location of the Vista Program Data Directory.

  3. SYSTEM_DOCUMENTS_DIR – provides the location of the current user’s documents directory e.g. C:\Documents and Settings\Administrator\My Documents – the pathname to the My Documents folder for an administrator on a Windows 2000 system.

  4. SYSTEM_TEMP-DIR – provides the location of the Windows’ Temp directory e.g. C:\DOCUME~1\ADMINI~1\LOCALS~1\Temp – the pathname to the folder for the administrator on Windows 2000 systems.

Note:
If these System variables are used to create a pathname, remember to place a backslash character between the variable name and the sub folders – see Using variables to create pathnames for more information.

SCORM Connectivity:

  1. There is a range of variables providing the Opus version of the corresponding SCORM data models e.g: LMS_LEARNER_ID would connect with the SCORM data model cmi.core.learner_ID

Note:
These variables are not connected to the relevant SCORM data models except in the SCORM template publications. They are providied in all publications merely for your convenience and you can use your own variables for the same function or rename these.

  1. In addition there are a couple of variables which the LMS Initialization or closedown process will update automatically so they can be checked to ensure the initialisation process has succeeded.

Note:
Because of the way communication with the LMS works there is some latency between the operations and the variables being updated. In addition you cannot monitor these variables using the Variable Changed trigger.

 

Username and Login Details

  1. LOGIN_USERNAME – to store the full username of the person logging in. The System_Username could be used as a default which the user could edit, clarify or extend or it can be requested explicitly from the user.

  2. LOGIN_FIRSTNAME – to store the user’s first name. Can be requested specifically or extracted from the Username using a QuickScript function

  3. LOGIN_SURNAME – to store the user’s second name. Can be requested specifically or extracted from the Username using a QuickScript function.

  4. LOGIN_USER_EMAIL – to store the user’s email address. To be input by the user/designer.

  5. LOGIN_TUTOR – to store the tutor for the course. To be input by the user/designer.

  6. LOGIN_MANAGER – to store the manager for the course. To be input by the user.

  7. LOGIN_TUTOR_EMAIL – to store the email address of the tutor if required. To be input by the user/designer.

  8. LOGIN_ORGANIZATION – the organization of the person logging in. Useful when training third party contractors for example. To be input by the user.

  9. LOGIN_USER_ID – A unique ID number for the logged in user. Could be obtained from user or from course database or calculated internally.

 

The Publication Information:

  1. CHAPTER_PASSWORD – this variable allows you to limit access to a chapter based on a password. This variable can only be used if you have set passwords for chapters in the Password tab of the Publication Properties dialog – see Passwords tab (especially point 7) for more information.

  2. PUBLICATION_TIME – contains the number of seconds the publication has been running since the user first opened it. This can be useful to time out a publication, if it has not been accessed for a while.

  3. PUBLICATION_TITLE – contains the title you have given to the publication as displayed in the organizer and the Publication Properties. This is not the same as the filename of the publication unless you have made it deliberatly so.

  4. PUBLICATION_PAGE_TITLE – contains the title of the current page as displayed in the organizer. Allows you to display the title of the page

  5. DATABASE_ERROR_MESSAGE – If you have used a database in your publication, this variable will contain any error messages sent via the database if there has been a problem connecting or accessing the database. The error message may help you (or the user if you display the variable on screen) to solve the problem.

  6. RADIO_GROUP_1_ID – contains the index position of the currently selected button in a group of radio buttons. This variable is only to be used if you have created Button objects on a page that are set to the Radio Button in the Buttons tab of the object Properties dialog.

For Example:

If you have 3 radio buttons on a page all part of Group 1, then each button in the list has an index number starting at index position 0 and counting up by 1 for each new button in the group. For example:

Button 1 – Index 0 Button 2 – Index 1 Button 3 – Index 2

If the user selects the object named Button 2, then this variable will contain the number 1 (i.e. the Index number). The variable below (point 5) will contain the name of the Button object – using this example, if the user selected Button 2; the variable will contain the name Button 2.

  1. RADIO_GROUP_1_NAME – contains the name of the Button object selected in group of radio buttons – see point 4 above.

Note:
Opus also provides other group numbered System variables e.g. RADIO_GROUP_2_ID – use the variable that matches the number you entered in the Group box of the Radio Button option.

  1. COMMAND_PARAM_COUNT – contains the number of parameters passed on the command line after the user runs the publication. For example, if the command line was myslideshow.exe /print – the /print is the parameter and COMMAND_PARAM_COUNT would contain the value 1 because there is only one parameter. This variable will then create a new variable for each parameter containing the actual parameter. Using the example above, there would be one new variable named COMMAND_PARAM_1 and it will contain the value print – see Passing Parameters in Launch File action for more information.

  2. PUBLICATION_EVALUATION – contains information about the current evaluation state of the publication. This variable only contains meaningful information if the evaluation options evaluation options have been set on the Security properties page; otherwise it will be -1.

 The possible values for this variable are:

Value

Meaning

Greater then 0

Number of days left for evaluation

0

Publication has expired

-1

Publication is not an evaluation publication

-2

Publication was an evaluation but it has been cleared by the Change Publication Evaluation action

Related Topics:

What are Variables?

Types of Variable

Creating Variables

Displaying Variables on a Page

Insert Variable or Expression Dialog

Creating Arrays in Opus