> > > >
"This looks like a very good idea for new projects..."> > > >
> > > > George,
> > > >
> > > > When you have the sizer that you want, why not retrofit your old forms. Create your new form class (inlcuding the sizer) and then open your form as a table and change the form's classlib and class name:
> > > >
> > > > USE [Path2\MyForm.SCX] IN 0 EXCL ALIAS MyForm
> > > > SELECT MyForm
> > > > LOCATE FOR BaseClass = [Form]
> > > > REPLACE Class WITH [MySizerFormClassName], ;
> > > > ClassLoc WITH [FulPath2\MyBaseClassLib.VCX]
> > > > USE IN SELECT([MyForm])
> > > >
> > > >
> > > > With VFP, just about everything is a table. Using ADIR() you could write a little program that looped through all of the forms in you Forms directory and change the class and classlib to your new new sizerform class.
> > > >
> > > >
> > > > Ken
> > > > You shall know the truth - and the truth shall set you free. (John 8:33)
> > >
> > > This is real good for application wide changes Ken!
> > > Question:
> > > Is it OK to insert "records" e.g. Command buttons
> > > If yes, What are the rules for assigning values for UniqueID and timestamp.
> > >
> > > George
> >
> > Unique IDs sys(2015)
> > TimeStamp I use seconds()*1000
> >
> > Regards
> > Tushar
>
> Thanks Tushar!
> I'm still experimenting.
>
> Ive written a small program which scans through a table of forms, opening each form in the file as a table, looks for a "marker" in INIT code, and inserts a new block of code immediately before the location of that "marker" code.
> Problem is:
> When I view the updated table (i.e. the form opened as a table) I can see my changes - perfectly. My block of code has been inserted at the correct position.
>
> However, When I open the form using
> modify form myform
> I DONT see the NEW code!!!
>
> EDITED LATER: I FOUND THE REASON FOR ABOVE BEHAVIOR
> After making changes to the form's table you must do this:
> compile FORM myform
>
> May be of interest to others (and save hairloss!)
>
> George
I forgot to tell you that yesterday. By today you had already found that out for yourself. Hope there wasn't too much hairloss :).
Some other things that may not be immediately apparent
In the record with class='form' , the field reserved3 has a list of methods / properties that you declare. Methods start with '*'. All properties seem to be listed first.
In the record with class='dataenvironment' , the field reserved2 has the Number of Tables + Number of Relationships +1.
Hope this prevents hairloss during your experiments.
Also check out
http://www.foxite.com/archives/0000119235.htmRegards
Tushar