This is a migrated thread and some comments may be shown as answers.

Hiding a column and still have it accessable in client-side JavaScript

1 Answer 69 Views
Grid
This is a migrated thread and some comments may be shown as answers.
Dick
Top achievements
Rank 1
Dick asked on 25 Mar 2009, 09:07 PM
I have a column in a grid that I use to hold a database key for the record displayed in the grid row.  This columns data should not be visible to the user.  I know I can set the visible attribute to "false" and it will not appear in the grid.  However when I do that, it is no longer accessable to my client side java script function, which is involked when the row is clicked.  Is there a way to accomplish this so that it is available to javascript while still not being displayed in the UI Grid. ???

1 Answer, 1 is accepted

Sort by
0
Shinu
Top achievements
Rank 2
answered on 26 Mar 2009, 03:37 AM
Hi Dick,

Try hiding the Column using the Display property instead of the Visible property.

ASPX:
 
 
<telerik:GridBoundColumn DataField="ProductName"    Display="false"  HeaderText="ProductName" SortExpression="ProductName" 
                        UniqueName="ProductName"
                    </telerik:GridBoundColumn> 


Thanks
Shinu
Tags
Grid
Asked by
Dick
Top achievements
Rank 1
Answers by
Shinu
Top achievements
Rank 2
Share this question
or