Hi all, I am having trouble with the visible property of an GridTemplateColumn.
I have an AutoGenerated EditType edit screen because of the dynamic nature of the requirement. I have added a necessary dropdown onto this edit area by adding an GridTemplateColumn to the <Columns> area of the radgrid.
I need this GridTemplateColumn to only be visible under certain circumstances but I have no luck. Setting the visible property = "false" in the tag itself does not work. Nor does setting the .Display, .ReadOnly or .Visible properties in the code behind. I have tried hooking into the column in both ItemDataBound and PreRender events. I have tried finding the column from the MasterTable and other methods as well.
Every time I find the column correctly (verified by debugging the UniqueName) but the column is always visible.
I tried adding a label inside the GridTemplateColumn and set EditFormHeaderTextFormat to an empty string but the column space is reserved and thus my label is indented.
A solution to either would solve this issue. Need some help please!
Thanks :)
EDIT - My column is of type EditItemTemplate so that it shows on the Edit Form. If I change it to ItemTemplate I am able to make the column Visible = false
I have an AutoGenerated EditType edit screen because of the dynamic nature of the requirement. I have added a necessary dropdown onto this edit area by adding an GridTemplateColumn to the <Columns> area of the radgrid.
I need this GridTemplateColumn to only be visible under certain circumstances but I have no luck. Setting the visible property = "false" in the tag itself does not work. Nor does setting the .Display, .ReadOnly or .Visible properties in the code behind. I have tried hooking into the column in both ItemDataBound and PreRender events. I have tried finding the column from the MasterTable and other methods as well.
Every time I find the column correctly (verified by debugging the UniqueName) but the column is always visible.
I tried adding a label inside the GridTemplateColumn and set EditFormHeaderTextFormat to an empty string but the column space is reserved and thus my label is indented.
A solution to either would solve this issue. Need some help please!
Thanks :)
EDIT - My column is of type EditItemTemplate so that it shows on the Edit Form. If I change it to ItemTemplate I am able to make the column Visible = false