allvariables: How To

This may be a nooby question, but I am trying to work with the allvariables collection on a form so I can reset their value to null, but I can’t figure out the syntax. Can someone show me a simple method to nullify them?

this is what I tried:

var allvars=allvariables
for(i in allvars){
allvars*=null;*
}
I can see the list of var names, but I can’t figure out how to use that info.
Thanks.

Try this:

var allvars = allvariables;
for(i in allvars){
	forms.yourFormName[allvars[i]] = null;
}