Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Programmatically scrolling
Message
Information générale
Forum:
ASP.NET
Catégorie:
Formulaires
Versions des environnements
Environment:
C# 2.0
OS:
Windows XP SP2
Divers
Thread ID:
01214513
Message ID:
01216544
Vues:
10
Can't you just set the .CurrentRowIndex?

>I've just begun to play around with DataGridView, so I'm not the best one to answer your question, but seeing as no one has replied yet, I'll give it a shot.
>
>How did you programmatically select the row? There's probably other ways to do this that I have not explored yet, but I found that if you set the MyGrid.CurrentCell to a cell in the row you're wanting to select, then it will scroll there automatically. So, something like this:
>
>
>this.MyGrid.CurrentCell = this.MyGrid.Rows[theRowIndex].Cells[0];
>
>
>It worked for me, although it's probably not the correct way to do it ... I'm just not experienced enough yet with Grids to know the correct way.
>
>C'mon! Where are all the Grid guys?!?!?! Someone needs to help out Richard!
>
>(I'll play with it a little more as I have time Richard, but in the meantime, I hope someone else will jump in with an answer).
>
>~~Bonnie
>
>
>
>
>>How do you scroll a DataGridView programmatically? I have selected a row programmatically that is outside of the viewable area. How can I scroll to that row?
>>
>>Richard
Regards,

E.R. Gilmore
Précédent
Répondre
Fil
Voir

Click here to load this message in the networking platform