I am looking at a way to get the value on column 2, when the user selects a row.
For example: the datagrid shows like this:
Row Name Location
1 Picture 1 c:\pic_1.bmp
2 Picture 2 c:\pic_2.bmp
3 Picture 3 c:\pic_3.bmp
I am able to get the value from using datagrid.currentcell.value.tostring, but I have to click exactly at the cell to get the current value.
If the user click on row 2, I want to get the value from LOCATION columns in row 2 (the value is "c:\pic_2.bmp"), usually in VB 6.0 I would write it like:
dim x as string
x = datagrid.columns(2).value
So x = c:\pic_2.bmp
Right now with datagrid.currentcell.value.tostring, the user have to click on "c:\pic_2.bmp" in order to get the correct value. So is there a way to code it so when user click the row, go get the value from LOCATION column?
For example: the datagrid shows like this:
Row Name Location
1 Picture 1 c:\pic_1.bmp
2 Picture 2 c:\pic_2.bmp
3 Picture 3 c:\pic_3.bmp
I am able to get the value from using datagrid.currentcell.value.tostring, but I have to click exactly at the cell to get the current value.
If the user click on row 2, I want to get the value from LOCATION columns in row 2 (the value is "c:\pic_2.bmp"), usually in VB 6.0 I would write it like:
dim x as string
x = datagrid.columns(2).value
So x = c:\pic_2.bmp
Right now with datagrid.currentcell.value.tostring, the user have to click on "c:\pic_2.bmp" in order to get the correct value. So is there a way to code it so when user click the row, go get the value from LOCATION column?