>I am trying to save the current value of a control. For example:
>
>THISFORM.PageFrame1.Page1.cmdAdd1.Enabled = .F.
>
>I would like to save the current value of .F. and then be able to change the control back once I return to page 1 from page 2.
>
>TIA,
You could make it an array property of the pageframe, one row per button, and column per frame. So, when leaving a page, you could just call this pageframe's method:
* pageframe.savebuttons
for i=1 to this.the_buttons.buttoncount
this.ButtonsArray[i, this.activepage]=this.the_buttons[i].enabled
endfor
* pageframe showbuttons:
Lparam nActivatingPage
for i=1 to this.the_buttons.buttoncount
this.the_buttons[i].enabled=this.ButtonsArray[i, nActivatingPage]
endfor
You may play with a proper place to call these from, but page Activate/Deactivate seems a good place.