Search your code for a similarly named base class. This sounds like one of
the weird behaviors Christof explained in one of his SWFox presentations.
VFP might be linking the base to a different base then you might want it to
via a cache.

I've also seen it with setting a property on a form at instantiation, the
next time it is set, it doesn't get a new value.

HTH,

Tracy

-----Original Message-----
From: Dave Crozier
Sent: Wednesday, March 19, 2008 4:12 AM

Guys,
I have a really, really weird behavioural problem here with VFP and I'm
pulling my hair out - what little I have.

Simple scenario:

1. A form subclassed from a base form.

2. The base form contains code in the Load() event

3. The production form calls the default code in the base class Load() using
Default()

4. In the Baseclass I instantiate a few business Objects and drill down
about 3 or 4 stack levels to create various objects etc.

90% of time this works fins, but about 10% of the time the Dodefault() in
the production form simply refuses to run the baseclass Load() code. Note
that this is only in design mode and when you trace through the program and
step into the DoDefault() nothing happens and execution is immediately
passed to the line following the DoDefault().

Once this happens once you can cancel the form and re-run it as many times
as you like with EXACTLY the same effect - a skip over DoDefault(). I have
tried all of the individual "close" statements e.g. "close procedures" etc
and nothing resets the problem apart from a "close all", reopening of the
project and running the form again.

The only thing that I have done differently to my normal procedures is to
make more use of "try...endtry" and I am wondering if there is a "dangling
reference" somewhere which is firing me back from the baseclass code
immediately so I never even get into the subclassed coding, but how to find
it easily I can't work out - if it is in fact that problem. Ideally I would
like a "clear try" command or the equivalent!

I am not convinced that the "try...endtry" is the cause of the problem but
thought I would ask around to see if anyone else has had similar
experiences.

Dave Crozier




_______________________________________________
Post Messages to: [email protected]
Subscription Maintenance: http://leafe.com/mailman/listinfo/profox
OT-free version of this list: http://leafe.com/mailman/listinfo/profoxtech
Searchable Archive: http://leafe.com/archives/search/profox
This message: http://leafe.com/archives/byMID/profox/[EMAIL PROTECTED]
** 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.

Reply via email to