Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Grid: Set enable property depending on a value
Message
 
 
À
19/04/2010 08:14:55
Information générale
Forum:
Visual FoxPro
Catégorie:
Codage, syntaxe et commandes
Versions des environnements
Visual FoxPro:
VFP 9 SP2
OS:
Windows 7
Network:
Windows 2003 Server
Database:
Visual FoxPro
Application:
Desktop
Divers
Thread ID:
01460890
Message ID:
01460896
Vues:
41
>The program will be used to keep track of questions answered by customers. The customer will be phoned and then as he answers the set questions, the data will be captured via this program. The recordsource of the grid is a table in my database. On the add event I insert all the questions, stored in a table, into the table that is the recordsource of the grid. Now the user can read the questions off the grid and type the answer as the customer replies.
>
>The problem I have is that certain questions requires a yes/no (logical) answer and others will required a sentence or word. In the database in the same table where the questions are stored, I also keep whether the question will required a logical or comment for the answer. Depending on these value, I want to disable the cell of the grid. E.g. when the answer requires a text answer (comment), then I want to set the enable property of the logical (yes/no) columns to false. For one row in the grid the yes/no column must be enabled and for the other row(s) it must be disabled.
>
>Is this possible and is so, how?
>
>Thanks
>
>Irene

One possibility would be to manipulate column's (grid's) ReadOnly property depending on the field's value in AfterRowColChange event of the grid.
If it's not broken, fix it until it is.


My Blog
Précédent
Suivant
Répondre
Fil
Voir

Click here to load this message in the networking platform