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 many of which already contain information. For example, the PUBLICATION_TIME variable contains the current time the user has been running the publication. Other variables are provided to make it easier for you to add particular values – such as the total number of questions in a quiz/test.

The System variables contain information about the system that it is currently working on and are constantly updated by Creator. 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 Page templates – see Using Question Pages in Creator 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. 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:

The SCORE_ prefix is a category indicator to keep all these variables together and should not be read literally.

  1. SCORE – Manual – This is a variable for you to store custom scores independently of the Creator scoring system variables detailed below. Use the Set Variable or Add/Subtract actions to alter this variable to keep track of scores yourself. Useful for scoring in games which do not need the other scoring calculations.

  2. SCORE_VALUE – Automatic – Calculates the total value of scores for the answer so. Use this to display the points scored. For example, the user must answer find 4 correct questions with scores allocated thus: Q1 = 1, Q2 = 3, Q5 = 5 and Q6 = 2. If the user only selects the first three answers the score value would be 9. If all answers were selected the score would have been 11.

  3. SCORE_VALUE_TOTAL – Automatic – Calculates the total possible value of the answers which have been selected, whether the user answered the question correctly or not. This value will only differ from SCORE_VALUE if you are providing some answers which are given partial scores e.g: 1 point out of a possible 2 (suggesting that while this answer is correct another answer would be a fuller answer – this is particularly useful when scoring text input answers).

  4. 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.

  5. SCORE_CORRECT – Automatic – This variable contains the number of correct answers which have been given so, e.g. 5 out of 7 answers. If each question only has one answer then this will also be the number of questions answered correctly.

  6. SCORE_INCORRECT – Automatic – This variable contains the number of incorrect answers provided e.g. 2 out of 7 answers. If each question only has one answer then this will also be the number of questions answered correctly.

  7. SCORE_TOTAL – Automatic – Keeps track of the number of answers the user has given, 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 with 4 possible answers to each (whether they are correct or not), the user has attempted 7 questions and clicked on 2 answers for each, but only got 4 correct, the SCORE_TOTAL would be 14 but the SCORE_VALUE would be 4. This variable allows you to check that the user has not simply clicked on every button and also a low number of answers selected might indicate a lack of understanding.

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

  2. SCORE_TOTAL_POSSIBLE – Manual – A suggested variable in which to store the maximum possible score for the whole quiz/test irrespective of how many the user has answered. You need to calculate the value of all the answers in the test and then type this in via the Variables section of the Publication Properties.

  3. SCORE_CURRENT_POSSIBLE – Manual – User-defined variable to store the total possible score. It should be calculated as SCORE_TOTAL_POSSIBLE minus SCORE_VALUE_TOTAL using the Set Variable action on the Programming tab.

  4. 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 go back over the training until a pass level is maintained. Or it useful to check that the final mark is adequate for a pass certificate.

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 Creator 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/Windows7 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.

 

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.

  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. 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:
Creator 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.

Related Topics:

What are Variables?

Types of Variable

Creating Variables

Displaying Variables on a Page

Insert Variable or Expression Dialog

Creating Arrays in Creator