Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Object is skipping sub-code
Message
From
03/07/2003 17:44:03
 
 
To
All
General information
Forum:
Visual FoxPro
Category:
Classes - VCX
Title:
Object is skipping sub-code
Miscellaneous
Thread ID:
00806776
Message ID:
00806776
Views:
55
Nevermind, somehow my vcx file got 2 classes with the same name in it. And obviously my code was running the one I wasn't editing.

I created a property along with the assign() method.

I put code into the assign() method changing the caption on another control in the class.

I created a sub-class and put code into the assign() changing the caption on another control added in the sub-class. The code in the sub-class never executes.
define mySubClass as myClass
enddefine

myClass.myProperty_Assign()
  lparameters vNewVal
  this.myProperty = vNewVal
  this.myControl_1.caption = 'Close ' + this.myProperty

mySubClass.myProperty_Assign()
  lparameters vNewVal
  dodefault(vNewVal)
  this.myControl_2 = 'Open ' + this.myProperty
When I trace through it, as soon as I assign a value to myProperty, it immediately jumps to myClass.myProperty_Assign(), it skips over mySubClass.myProperty_Assign()
I've tried putting nodefault in the code, didn't help.

TIA
Bill Morris
Next
Reply
Map
View

Click here to load this message in the networking platform