Information générale
Catégorie:
Gestionnaire d'écran & Écrans
>>Hi all
>>I have created a Grid with recordsourcetype=Alias & given table name in record source. Grid has seven columns. Now programatically I assign controlsource to each column. For example
>>thisform.grid1.column1.controlsource=aliasname.fieldname
>>current control of each column is text1
>>Grid is readonly & all columns are also readonly.
>>Now when I append a record in the table to which grid is bound. All columns are showing data perfectly. But when I check for the text values, it shows nothing.
>>(ie if column1 is showing "abcd", text1.value is not "abcd" it is blank)
>>I tried this by assigning controlsource proerty of text control also but same result.
>>Am I doing anything wrong??
>>
>>TIA
>
>First of all, text.value will reflect field value of the current table. May be you should also issue grid.refresh. Anyway, if your grid is read-only you probably don't need to check value properties at all?. Instead of this you better check field value of the recordsource.
Yes, I am doing grid.refresh, but results are same. I also beleive that text value must reflect the field values but it is not.
I actually want to set DynamicForeColor property of the column based on text contents. (ie thisform.grid1.column1.DynaForeColor="iif(
...column1.text1.value="Error",RGB(255,0,0),RGB(0,255,0))"
Narendra
Précédent
Suivant
Répondre
Voir le fil de ce thread
Voir le fil de ce thread à partir de ce message seulement
Voir tous les messages de ce thread
Voir tous les messages de ce thread à partir de ce message seulement