Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Programmatically scrolling
Message
De
16/04/2007 16:32:40
 
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:
01216492
Vues:
19
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
Bonnie Berent DeWitt
NET/C# MVP since 2003

http://geek-goddess-bonnie.blogspot.com
Précédent
Suivant
Répondre
Fil
Voir

Click here to load this message in the networking platform