Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Strange behaviour when subclassing grid
Message
De
27/03/2003 17:17:15
 
 
Information générale
Forum:
Visual FoxPro
Catégorie:
Classes - VCX
Divers
Thread ID:
00770945
Message ID:
00771042
Vues:
15
Perfect, Thanks.

Column.textbox.dblClick = This.Parent.Parent.dblClick





>Click and DblClick methods would work only if your grid doesn't have records. Otherwise column.textbox.Click and DblClick methods are executed instead. If you're using VFP8, you can use BindEvents to execute your code. Otherwise you have to substitute standard textbox with your custom textbox. There is a FAQ by Mike Helland here, which shows, how to do it.
>
>>Hi.
>>
>>I have been finding some troubles when subclassing a grid.
>>
>>I create a Classlib which contains a basic VFP Grid, with custom backcolor in Column1 and custom messages in some methods in order to test:
>>
>>MyGrid.DblClick contains: Wait window "DoubleClick"
>>MyGrid.Clcik contains: Wait window "Click"
>>MyGrid.AfterRowColChange contains: Wait window "AfterRC"
>>
>>
>>When I drop the class from the classlib into the form, the backcolor property is lost.
>>When I run the form, AfterRowColChange works ok, but the others don't display the custom message (Click and DoubleClick).
>>
>>
>>Any comments ?
>>
>>Thanks
>>
>>Juan C.
Précédent
Répondre
Fil
Voir

Click here to load this message in the networking platform