Stg_set()
Description: |
API procedure, writes (sets) the value of the specified setting's member; reports errors through callback_stg_error(). |
Syntax: |
sub stg_set(byref stg_name_or_num as string, index as byte, byref stg_value as string) |
See Also: |
Parameter |
Description |
stg_name_or_num |
Setting name or number. If the supplied string does not start with a digit (0-9), then the string is interpreted as the name of the setting. If the string starts with a digit, then this will be interpreted as the setting number. Settings are numbered counting from 0, and in the order of their appearance in the setting configurator. |
index |
Setting member. |
stg_value |
New setting member's value to be set. |
stg_timestamp variable |
When STG_TIMESTAMP is 1, this global variable should be preset with the desired timestamp prior to calling stg_set(). |
Details
Callback_stg_error() is invoked if any error is detected during this procedure's execution. One of the following errors could be reported: EN_STG_STATUS_OK, EN_STG_STATUS_NOT_STARTED, EN_STG_STATUS_UNKNOWN, EN_STG_STATUS_INVALID_INDEX, EN_STG_STATUS_FAILURE, EN_STG_STATUS_INVALID.
Callback_stg_post_set() is called when this procedure executes. This provides a "central location" for responding to changing setting values.