Interesting to know ....
I have a LightWeight base class. One I use to make invisible classes (Queue, stack, etc)
I had it based on a relation. I have an Image class >> Heigth/Width
A few days ago, I found in FoxWiki that the cursor class destroys faster. So I decided to base the LightWeight on a cursor class
Until I found out that the cursor gives an error
So, I'll base it on a custom class - that is one error I won't have when I switch to vfp9
Thanks,
_______________________
>They both geives me error in VFP9
>
>>>What do you expect to happen? Neither width nor height are available properties for these classes!
>>
>>I knew I would get an answer like this.
>>
>>They may not be 'available', but they can be defined
>>
>>The thing is, why does it work with a relation and gives an error on a cursor class ?
>>________________
>>>>Something funny I've come across
>>>>
>>>>If you have a class based on cursor, avoid the Width property (Height as well)
>>>>
>>>>
>>>>xxx = createobject('test1', 20)
>>>>xxx = createobject('test2', 20)
>>>>
>>>>define class test1 as cursor
>>>>
>>>> width = 0
>>>>function init( Width )
>>>>
>>>> this.Width = min(m.width, this.Width)
>>>> ?this.Class, this.Width
>>>>
>>>>endfunc
>>>>enddefine
>>>>
>>>>define class test2 as relation
>>>>
>>>> width = 0
>>>>function init( Width )
>>>>
>>>> this.Width = min(m.width, this.Width)
>>>> ?this.Class, this.Width
>>>>endfunc
>>>>enddefine
>>>>
Gregory