Home All Groups Group Topic Archive Search About
Author
10 Aug 2006 3:37 PM
Samuel Shulman
I want to programatically select a row in the list and make it visible in
case the row is not already visible because of the length of the list


Thanks in advance,
Samuel

Author
10 Aug 2006 7:47 PM
Brian Tkatch
Samuel Shulman wrote:
> I want to programatically select a row in the list and make it visible in
> case the row is not already visible because of the length of the list
>
>
> Thanks in advance,
> Samuel


I am actually about to do this myself, to implement a find feature for
a DataGridView.

You should be able to do this via DataGridView.CurrentCell

BTW, please do not rely on people reading the subject line of your
message. In fact, write the subject line *after* the message. I have no
idea why it is on top, encouraging people to title something they
haven't written yet.

B.
Author
10 Aug 2006 10:27 PM
Samuel Shulman
that works, thank you

I find that there is relatively little knowledge about this control which is
extremely useful

Samuel


Show quoteHide quote
"Brian Tkatch" <Maxwell_Sm***@ThePentagon.com> wrote in message
news:1155239251.102388.117730@75g2000cwc.googlegroups.com...
> Samuel Shulman wrote:
>> I want to programatically select a row in the list and make it visible in
>> case the row is not already visible because of the length of the list
>>
>>
>> Thanks in advance,
>> Samuel
>
>
> I am actually about to do this myself, to implement a find feature for
> a DataGridView.
>
> You should be able to do this via DataGridView.CurrentCell
>
> BTW, please do not rely on people reading the subject line of your
> message. In fact, write the subject line *after* the message. I have no
> idea why it is on top, encouraging people to title something they
> haven't written yet.
>
> B.
>
Author
11 Aug 2006 5:11 AM
Cor Ligthert [MVP]
Samuel,
>
> I find that there is relatively little knowledge about this control which
> is extremely useful
>
I would not say so it is constantly growing, however especially Ken is
constantly putting more information about the DataGridView on our website.

http://www.vb-tips.com/dbpages.aspx?IA=DG2

You can have a look at the CodeCamp button as well to see Ken's presentation
about the DataGridView

I hope this helps,

Cor

Show quoteHide quote
> Samuel
>
>
> "Brian Tkatch" <Maxwell_Sm***@ThePentagon.com> wrote in message
> news:1155239251.102388.117730@75g2000cwc.googlegroups.com...
>> Samuel Shulman wrote:
>>> I want to programatically select a row in the list and make it visible
>>> in
>>> case the row is not already visible because of the length of the list
>>>
>>>
>>> Thanks in advance,
>>> Samuel
>>
>>
>> I am actually about to do this myself, to implement a find feature for
>> a DataGridView.
>>
>> You should be able to do this via DataGridView.CurrentCell
>>
>> BTW, please do not rely on people reading the subject line of your
>> message. In fact, write the subject line *after* the message. I have no
>> idea why it is on top, encouraging people to title something they
>> haven't written yet.
>>
>> B.
>>
>
>
Author
11 Aug 2006 6:13 AM
Cor Ligthert [MVP]
Brian and Samuel,

> BTW, please do not rely on people reading the subject line of your
> message. In fact, write the subject line *after* the message. I have no
> idea why it is on top, encouraging people to title something they
> haven't written yet.

Some newsreaders will try to find the same subject and place that in top of
an existing one.
(Which can be depending the options set for that newsreader and if it still
exist on the newsserver, but the latest is often with Google when the
subject is not good set).

Therefore it is not clever to use a Subject as "DataGridView" or by instance
"Help".

(In this way you can by instance reset the date and time by *newsgroup*
topposters. Don't confuse this with email topposters).

I hope this gives an idea,

Cor
Author
11 Aug 2006 5:36 AM
gene kelley
On Thu, 10 Aug 2006 16:37:46 +0100, "Samuel Shulman" <samuel.shul***@ntlworld.com> wrote:

>I want to programatically select a row in the list and make it visible in
>case the row is not already visible because of the length of the list
>
>
>Thanks in advance,
>Samuel
>

If you know the RowIndex of the selected item:

Me.DataGridView.FirstDisplayedScrollingRowIndex = Value

Where value is the Row Index to be displayed at the first visible position


Gene
Author
11 Aug 2006 1:32 PM
Brian Tkatch
gene kelley wrote:
Show quoteHide quote
> On Thu, 10 Aug 2006 16:37:46 +0100, "Samuel Shulman" <samuel.shul***@ntlworld.com> wrote:
>
> >I want to programatically select a row in the list and make it visible in
> >case the row is not already visible because of the length of the list
> >
> >
> >Thanks in advance,
> >Samuel
> >
>
> If you know the RowIndex of the selected item:
>
> Me.DataGridView.FirstDisplayedScrollingRowIndex = Value
>
> Where value is the Row Index to be displayed at the first visible position
>
>
> Gene

Very nice. I think this is what i will use.

These names are so confusing. :)

B.
Author
11 Aug 2006 7:24 PM
gene kelley
Show quote Hide quote
On 11 Aug 2006 06:32:29 -0700, "Brian Tkatch" <Maxwell_Sm***@ThePentagon.com> wrote:

>
>gene kelley wrote:
>> On Thu, 10 Aug 2006 16:37:46 +0100, "Samuel Shulman" <samuel.shul***@ntlworld.com> wrote:
>>
>> >I want to programatically select a row in the list and make it visible in
>> >case the row is not already visible because of the length of the list
>> >
>> >
>> >Thanks in advance,
>> >Samuel
>> >
>>
>> If you know the RowIndex of the selected item:
>>
>> Me.DataGridView.FirstDisplayedScrollingRowIndex = Value
>>
>> Where value is the Row Index to be displayed at the first visible position
>>
>>
>> Gene
>
>Very nice. I think this is what i will use.
>
>These names are so confusing. :)
>
>B.

Yes, it is/was confusing.  For years, this generally is commonly called "EnsureVisible" as is the
case with the ListView.

Gene