Are you selecting the 'value' to pass to the variable in the script or a front end table object?
Via the front-end you'll have to associate it with a variable that remains persistent after the reload has been initiated, conversley within the script you need to tell the variable which is the correct record eg:
Let vMyVariable = peek('MyData',-1,'site');
The above would select the bottom record from the previously loaded table 'MyData'.
Perhaps posting an example file would help matters.