lrc_save_BYTE
| Parameterization ("save") Functions |
Saves a BYTE value to a string parameter.
int lrc_save_BYTE( const char* param_name, BYTE val );
int lrc_save_BYTE_by_ref( const char* param_name, BYTE *val );
| param_name | The parameter to store the byte value. |
| val | The value to be saved. |
The lrc_save_BYTE function saves a byte to a string parameter.
The lrc_save_BYTE_by_reffunction saves the byte pointed to by "val" to a string parameter.
VuGen generates these functions as commented-out calls. To use the parameter, change the recorded param_name argument to a meaningful name and uncomment the call.
Return Values
Parameterization
You cannot use standard parameterization for any arguments in this function.
Example
This example first saves the octal value 131 to parameter, "CharacterParam", as character `Y' then saves the hexadecimal value 50 as character `P':
Action()
{
BYTE byteVal;
byteVal = lrc_BYTE("\131");
lr_output_message("Octal 131 = Decimal %u", byteval );
lr_output_message("Octal 131 = Hex %X", byteval );
lr_output_message("Octal 131 = char %c", byteval );
lrc_save_BYTE("CharacterParam", byteval );
bVal = lrc_BYTE("\x50");
lr_output_message("Hexadecimal 50 = Decimal %u", byteval );
lr_output_message("Hexadecimal 50 = Oct %o", byteval );
lr_output_message("Hexadecimal 50 = char %c", byteval );
lrc_save_BYTE("CharacterParam", byteval );
return 0;
}Example:
Action.c(7): Octal 131 = Decimal 89
Action.c(8): Octal 131 = Hex 59
Action.c(9): Octal 131 = char Y
Action.c(11): Notify: Saving Parameter "CharacterParam = Y"
Action.c(15): Hexadecimal 50 = Decimal 80
Action.c(16): Hexadecimal 50 = Oct 120
Action.c(17): Hexadecimal 50 = char P
Action.c(19): Notify: Saving Parameter "CharacterParam = P"

