Bet nobody is smart enough to solve this!!

G

G Dean Blake

This datagrid (dgbudgets) binds perfectly and column4 is a non visible
column.
Immediately after the bind, however, column(4).visible is true both in the
grid and the
grid retrieved from the session variable. This is my first mystery - it
should be
false and the column does indeed not show.

private sub Page_Load.....
if not isPostBack then
daBudgets.Fill(dsBudgets1)
dgbudgets.DataBind()
Session("myGrid") = dgbudgets
Dim anotherGrid As DataGrid = Session("myGrid")
Dim myboolean2 As Boolean = anotherGrid.Items(0).Cells(4).Visible
Dim myboolean1 As Boolean = dgbudgets.Items(0).Cells(4).Visible
..
..
In the following click event, however myboolean1 is still true but
myboolean2 is False
(as it should be). The mystery here is how did it become true (as it should
have been)
since it was retrieved from the very same session variable??

Private sub button1_Click......
Dim anotherGrid As DataGrid = Session("myGrid")
Dim myboolean2 As Boolean = anotherGrid.Items(0).Cells(4).Visible
Dim myboolean1 As Boolean = dgbudgets.Items(0).Cells(4).Visible

Can anyone help me solve this mystery?
hope so,
G
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

No members online now.

Forum statistics

Threads
473,770
Messages
2,569,586
Members
45,084
Latest member
HansGeorgi

Latest Threads

Top