The user pointer is of type long. It can contain a numeric value, or point to any type of variable or structure. Install a user pointer to a data object in a form, data field or memo field with the user pointer set function, userp_set():
|
||
|
|
|
|
|
|
For example, you can place a pointer to an integer in a data field with:
|
You should be sure that the variable pointed to by the user pointer is available for use when you access this value. If the variable pointed to by the user pointer is out of scope, a memory overwrite will occur in your code.