From: Mitch5713 on
I have a flexgrid populated by various numerical data. How do I get the value
when a user double clicks a cell????

Thanks
From: Rick Rothstein (MVP - VB) on
>I have a flexgrid populated by various numerical data.

If it is in an MSFlexGrid control, it is textual data, not numeric data. If
you need to use it as a number after retrieval, you should use one of the
Cxxx functions to convert it.


> How do I get the value when a user double clicks a cell????

You can use the TextMatrix method coupled with the MouseRow and MouseCol
properties. For example,

Private Sub MSFlexGrid1_DblClick()
With MSFlexGrid1
Debug.Print .TextMatrix(.MouseRow, .MouseCol)
End With
End Sub


Rick


From: Mitch5713 on
OK however it seems with that code you have to specify the row and col i.e.
MouseRow Mouse col but the user double clicks anywhere on the grid and I need
to get that number????

"Rick Rothstein (MVP - VB)" wrote:

> >I have a flexgrid populated by various numerical data.
>
> If it is in an MSFlexGrid control, it is textual data, not numeric data. If
> you need to use it as a number after retrieval, you should use one of the
> Cxxx functions to convert it.
>
>
> > How do I get the value when a user double clicks a cell????
>
> You can use the TextMatrix method coupled with the MouseRow and MouseCol
> properties. For example,
>
> Private Sub MSFlexGrid1_DblClick()
> With MSFlexGrid1
> Debug.Print .TextMatrix(.MouseRow, .MouseCol)
> End With
> End Sub
>
>
> Rick
>
>
>
From: Bob Butler on
"Mitch5713" <mitch(a)nnex.net> wrote in message news:C3E19CA0-6B20-4F53-
A0F7-47E409E05C8B(a)microsoft.com
> OK however it seems with that code you have to specify the row and
> col i.e. MouseRow Mouse col but the user double clicks anywhere on
> the grid and I need to get that number????

Not MouseRow and MouseCol, .MouseRow and .MouseCol -- they are properties of
the control

--
Reply to the group so all can participate
VB.Net: "Fool me once..."

From: Mitch5713 on
That seems to just return an arbitrary value not the value of the row and col
the user double clicked?????

"Bob Butler" wrote:

> "Mitch5713" <mitch(a)nnex.net> wrote in message news:C3E19CA0-6B20-4F53-
> A0F7-47E409E05C8B(a)microsoft.com
> > OK however it seems with that code you have to specify the row and
> > col i.e. MouseRow Mouse col but the user double clicks anywhere on
> > the grid and I need to get that number????
>
> Not MouseRow and MouseCol, .MouseRow and .MouseCol -- they are properties of
> the control
>
> --
> Reply to the group so all can participate
> VB.Net: "Fool me once..."
>
>