Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Member OBJECT does not evaluate to an object
Message
From
19/06/2008 11:46:18
Dragan Nedeljkovich (Online)
Now officially retired
Zrenjanin, Serbia
 
 
General information
Forum:
Visual FoxPro
Category:
Classes - VCX
Miscellaneous
Thread ID:
01325367
Message ID:
01325475
Views:
12
>This works:
>
>Put an RTF control on a form. In Init() and Resize() of control have:
>
this.object.rightmargin = this.width - 25
>
>The form runs fine. So far so good.
>
>Now I saved the control as a class.
>When I use the class on a form, and run the form, it gives this error message for Resize():
>"Member OBJECT does not evaluate to an object".
>
>The Init() does not give the error.
>
>So I tried changing the Resize() code to:
>
this.rightmargin = this.width - 25
>But that does not work either. The error is: Property RIGHTMARGIN is not found.
>
>So to get it to work, I have to clear the Resize() of the class, and put the this.object.rightmargin = etc into Resize() after it is on the form.
>
>Is there an obvious mistake here?

Not sure that it will fix anything, but you may try to avoid putting rtfbox (or any other activeX) directly on the form. Subclass it somewhere, then put that subclassed control where you need it. The instantiation is somewhat different - some activeX controls used to detect direct instantiation as "used in development" and would start checking for development license; if you instantiate a subclass, it detects a runtime instantiation, and all is fine. Not sure that this approach would change anything in your case, but it may be worth a try.

back to same old

the first online autobiography, unfinished by design
What, me reckless? I'm full of recks!
Balkans, eh? Count them.
Previous
Reply
Map
View

Click here to load this message in the networking platform