Callback_stg_pre_get()

Top  Previous  Next

Description:

Callback procedure, informs that the setting member's value is being read through one of the STG library's procedures; allows to update the setting member's value before it is returned by the STG library. Procedure body has to be created elsewhere in the project (externally with respect to the library).

Syntax:

sub callback_stg_pre_get(byref stg_name_or_num as string, index as byte, byref stg_value as string)

Returns:

---

See Also:

Using Pre-gets and Post-sets

 


Part

Description

stg_name_or_num

Setting name or number. If the supplied string does not start with a digit (0-9), then the string should be interpreted as the name of the setting. If the string starts with a digit, then this should 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

Current value of the specified setting's member. Leave the value unchanged if there is no need to update the setting. Change the value of this argument to have the STG library set the setting's member to this new value.

Details

This procedure is invoked when the following procedures execute:

Stg_check_all() — for each setting being checked.

Stg_get() — for the setting being read from.

stg_sg(,,,EN_STG_GET) — for the setting being read from.

 

The following procedures can't be called from within callback_stg_pre_get() or recursion error will be generated by the compiler:

Stg_start()

Stg_check_all()

Stg_restore_multiple()

Stg_restore_member()

Stg_get()

Stg_set()

Stg_sg()