PC Review


Reply
Thread Tools Rate Thread

Datagrid.text value

 
 
Flying Whiz
Guest
Posts: n/a
 
      17th Sep 2004
I am trying to catch value from datagrid cell.

I am trying to pass the value into a variable as below.

VarGridVal = DataGrid1.Text

MsgBox(VarGridVal)

but in the message box the value I am getting is "DataGrid1" instead
of the cell value.

How can I get the value ?

Thanks
Whiz
 
Reply With Quote
 
 
 
 
Alex Feinman [MVP]
Guest
Posts: n/a
 
      19th Sep 2004
You need

Dim cell as DataGridCell = DataGrid1.CurrentCell
DataGrid1.Item(cell.RowNumber, cell.ColumnNumber).ToString()

--
Alex Feinman
---
Visit http://www.opennetcf.org
"Flying Whiz" <(E-Mail Removed)> wrote in message
news:(E-Mail Removed)...
>I am trying to catch value from datagrid cell.
>
> I am trying to pass the value into a variable as below.
>
> VarGridVal = DataGrid1.Text
>
> MsgBox(VarGridVal)
>
> but in the message box the value I am getting is "DataGrid1" instead
> of the cell value.
>
> How can I get the value ?
>
> Thanks
> Whiz



 
Reply With Quote
Reply

Thread Tools
Rate This Thread
Rate This Thread:

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
datagrid view (or datagrid) to text file =?Utf-8?B?cm9nZXJfMjc=?= Microsoft C# .NET 2 23rd Mar 2007 06:52 PM
DataGrid and text box JRD Microsoft Dot NET 5 20th Dec 2006 11:14 PM
How to change text direction of text box with asp.net datagrid control Santosh Microsoft ASP .NET 1 2nd Aug 2006 12:55 PM
DataGrid Text??? =?Utf-8?B?VGltOjouLg==?= Microsoft ASP .NET 2 7th Jun 2005 07:43 PM
text below datagrid Mortar Microsoft C# .NET 3 4th Oct 2004 11:42 PM


Features
 

Advertising
 

Newsgroups
 


All times are GMT +1. The time now is 02:41 AM.