AndrewMozley
Programmer
I would like to remember some values associated with a form so that on a second invocation of the form things - such as the date range of the report - default to the values I used earlier in the session.
At present I keep all my global variables for my application in a public object, goapp. So in the start program for the application, I say :
and then I create several variables which are of interest across the application
I would like to simulate static variables (which I know do not exist in VFP) for a particular form so that I can refer to them as e.g.
That is, I would like to keep these properties together, rather than saying :
How do I add the object Myauditform as a property of my global variable goapp? And, if I decide to do this in the Init() method of Myauditform, can I check for the existence of goapp.MyAuditform, so that I do not attempt to create it twice?
Hope I am not making too heavy weather of this !
At present I keep all my global variables for my application in a public object, goapp. So in the start program for the application, I say :
Code:
PUBLIC goapp
goapp = CREATEOBJECT("Custom")
and then I create several variables which are of interest across the application
Code:
goapp.AddProperty("UseCentres",1)
goapp.AddProperty("SysStYr")
I would like to simulate static variables (which I know do not exist in VFP) for a particular form so that I can refer to them as e.g.
Code:
goapp.Myauditform.Startdate
goapp.Myauditform.Enddate
That is, I would like to keep these properties together, rather than saying :
Code:
goapp.AddProperty("StartDate")
goapp.StartDate = Thisform.txtStartDate.value
How do I add the object Myauditform as a property of my global variable goapp? And, if I decide to do this in the Init() method of Myauditform, can I check for the existence of goapp.MyAuditform, so that I do not attempt to create it twice?
Hope I am not making too heavy weather of this !