From: Mitch5713 on 17 Aug 2006 10:18 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 17 Aug 2006 10:34 >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 17 Aug 2006 12:11 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 17 Aug 2006 12:15 "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 17 Aug 2006 12:24
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..." > > |