Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Grid class defined as read-only, but editing is allowed
Message
De
06/12/2006 13:28:56
Dragan Nedeljkovich (En ligne)
Now officially retired
Zrenjanin, Serbia
 
 
À
06/12/2006 10:20:36
Information générale
Forum:
Visual FoxPro
Catégorie:
Gestionnaire d'écran & Écrans
Versions des environnements
Visual FoxPro:
VFP 9 SP1
OS:
Windows XP SP2
Network:
Windows XP
Database:
Visual FoxPro
Divers
Thread ID:
01175216
Message ID:
01175326
Vues:
8
>Hi all,
>
>I created a grid class for the forms I'm designing with ReadOnly=.t.. When I pop this grid into one of the tabs in the pageframe in my form, I look at it's properties and see that ReadOnly is still .t.. But when I run the form, I'm able to edit records in the grid. If I put "this.mygrid1.ReadOnly=.t." in the tab's Activate property, the grid becomes read-only.
>
>Why is the read-only aspect of this grid going away when I run the form? I've got no code in there that changes it to ReadOnly=.f..

Can't be sure of that - the code may be anywhere. Somewhere in the parent classes, form, who knows.

Two ways to dig it out:
1) watch thisform.grid1.readonly in the debugger, with the break set on that. It may show "expression can't be evaluated" at times when some code runs which doesn't run inside the form, but you'll just have to step out of that. I've caught quite a few things that way. Painful, slow, works.

2) use Code References, search for Readonly on your project. It may report too many false positives, but the one real positive is what you're after.

back to same old

the first online autobiography, unfinished by design
What, me reckless? I'm full of recks!
Balkans, eh? Count them.
Précédent
Répondre
Fil
Voir

Click here to load this message in the networking platform