PC Review


Reply
Thread Tools Rate Thread

Can't access datagrid textbox values when visible=false

 
 
awightma
Guest
Posts: n/a
 
      9th Aug 2004
Hi,

I have a datagrid with a number of textboxes on it.
I want one column of my table to be visible=false because it contains
the id of the record from the table.
For some reason when I set visible=true on the aspx page I can access
it no problem, but when I set visible=false the value that is returned
is always equal to ""

Dim testing8 As String = CType(e.Item.Cells(8).Controls(1),
TextBox).Text
Dim testing9 As String = CType(e.Item.Cells(9).Controls(1),
TextBox).Text

these are two lines from my code. They are identical textboxes,
except that one has visible=true and on has visible=false.

The visible=true one returns the correct value, and the visible=false
one returns "".

Any suggestions would be much appreciated.

Cheers,

Andrew
 
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
problem with form controls set to visible = false - Access 2007 Julie Aldridge Microsoft Access Forms 3 24th Apr 2008 10:14 AM
How to get values of a textbox in a datagrid? =?Utf-8?B?d3J5dGF0?= Microsoft ASP .NET 2 7th Jun 2005 07:01 AM
Datagrid.columns(i).visible=false Diego Microsoft ASP .NET 1 20th Oct 2004 10:20 AM
Why visible=false only work sometimes on datagrid? Adam Smith Microsoft ASP .NET 3 21st Apr 2004 12:20 AM
True/False values in Datagrid Nathan Microsoft VB .NET 1 29th Mar 2004 06:57 AM


Features
 

Advertising
 

Newsgroups
 


All times are GMT +1. The time now is 04:11 AM.