Thanks Tracy and Alan but _screen.activeform is apparently not valid in my case and I have not been able to figure out how Alan's examples fit into my situation.
At this point my project is very simple with only one form. The app converts an incoming file and builds a cursor of records not already in the master file. The form is then opened and data validation code is run on the cursor with statistics on the batch reported on the form. When the form closes, so does the application. Everything will work okay if I put the data validation code into the form init event. At this point the statistics values are stored in properties of the form and updating them is very straightforward. I would, however, prefer to have the validation code in a separate file. The issue is getting the data from the .prg back to the calling form. I suspect that passing the form name to the function will be make it possible to access the form properties but I have not been able to figure out how to do so. Since I can't afford the time to learn this properly I will probably just proceed with the code directly in the init event. Thanks again, Joe On Sun, Jun 30, 2013 at 4:04 AM, Alan Bourke <[email protected]>wrote: > You could try in the Init(): > > Local llRet > > llRet = DoDefault() > > if llRet > This.MyProperty = myvalue; > endif > > return llRet > > > ... or use form classes rather than forms. Once you're dealing with an > object, it's easy: > > MyForm = CreateObject("MyFormClass") > MyForm.MyProperty = myvalue; > MyForm.Show() > > > > > > > > > On Sun, Jun 30, 2013, at 04:22 AM, Tracy Pearson wrote: > > Joe Yoder <[email protected]> wrote: > > > > >I've tried FormName.PropertyName = NewValue. I don't get an error but > > >the > > >property value does not change. I know I can pass the value back with > > >the > > >return and then change it using ThisForm.PropertyName but I am already > > >using that for another property value. > > > > > >Thanks in advance, > > > > > >Joe > > > > > > > Joe, > > > > Do you pass a reference to the form? > > > > You might be able to use _screen.activeform. Test it is a valid object > > before setting the value. > > > > -- > > Tracy > > [excessive quoting removed by server] _______________________________________________ Post Messages to: [email protected] Subscription Maintenance: http://mail.leafe.com/mailman/listinfo/profox OT-free version of this list: http://mail.leafe.com/mailman/listinfo/profoxtech Searchable Archive: http://leafe.com/archives/search/profox This message: http://leafe.com/archives/byMID/profox/cabqednusxfrwf5bhp11dcxqew6novkfjychazjekx_apcz0...@mail.gmail.com ** All postings, unless explicitly stated otherwise, are the opinions of the author, and do not constitute legal or medical advice. This statement is added to the messages for those lawyers who are too stupid to see the obvious.

