Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Grid and selected control
Message
De
17/09/1997 07:38:43
 
 
À
16/09/1997 09:16:13
Information générale
Forum:
Visual FoxPro
Catégorie:
Gestionnaire d'écran & Écrans
Divers
Thread ID:
00050135
Message ID:
00050361
Vues:
32
Thank you, Edward for your answer!

I use the commands, you suggested. But the text box sometimes remains active. So, as I wrote, changing row by keyboard from combo cell, or clicking to other row on any other cell in the text/combo column, the text box got focus, instead of combobox. (DynamicCurrentControl works only, if I change for other column cells than this combo/text.) So I put a Combo.SetFocus() command in the GotFocus event of the textbox. It works fine. (I tried other things, but this was only, that works.)

P.S. I include my code:

in init event of grid:
public nLastRecno
nLastRecno=RECNO()
this.column2.dynamiccurrentcontrol="iif(recno()#nLastRecno,'text1','combo1')"
this.column2.sparse=.f.

in AfterRowColChange event of Grid
nLastRecno=Recno()
this.refresh()

BB




>>Thank you, Edward for your answer!
>>I start to "play" with dynamiccurrentcontrol as you suggested. It started to work as I wanted, except ..
>>So, something is still wrong, because it show the combobox on starting the form and if I change row on different field, than this one, which contains combobox. But if I change the row from the field containing the combobox, on the next row (up or down is equal) a text box will appear. (for a very short period the combobox appears)
>>
>>Can you give me any suggestion?
>>
>>TIA
>>
>>BB
>>
>Probably, I would have to look at your code (how you reevaluate DynamicCurrentControl property) now. Remember, that you should Grid.Refresh in Grid.AfterRowColumnChange event.
Précédent
Suivant
Répondre
Fil
Voir

Click here to load this message in the networking platform