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

GridViewImageColumn.IsVisible = READONLY?

2 Answers 74 Views
GridView
This is a migrated thread and some comments may be shown as answers.
Curtis
Top achievements
Rank 1
Iron
Iron
Veteran
Curtis asked on 14 Feb 2018, 10:54 PM

Either this is a bug or I'm doing something really, really silly!  My money's on the 2nd option :)

I have a grid with a GridViewImageColumn that I have to set .IsVisible = False.

No matter what I do, it flips back to 'True'

What am I doing wrong? 

 

BTW - This happens both at-runtime (dynamically setting the IsVisible property for this column = False does nothing) AND it happens at design time:  You can load up the grid, select the Columns property, select the GridViewImageColumn and try changing IsVisible from True to False.  Doesn't work :(

 

Any help would be very much appreciated!

-Curtis

 

2 Answers, 1 is accepted

Sort by
0
Curtis
Top achievements
Rank 1
Iron
Iron
Veteran
answered on 14 Feb 2018, 11:05 PM

*SOLUTION*

Turns out if you want to hide a column you cannot just set "IsVisible" = False you also have to set "AllowHide" = True.

I was lead to believe "AllowHide" was determining whether or not the USER could hide the column.  IMHO "IsVisible" should override "AllowHide" and do what it says to do but I can make an equal case for leaving it as-is and since it's already as-is...I'm done :)

 

0
Dimitar
Telerik team
answered on 16 Feb 2018, 09:13 AM
Hello Curtis,

Yes, this is a bit confusing but please note that it is the default behavior since 2010. You feedback is noted and we will reconsider this if we receive more request for it. 

Should you have any other questions do not hesitate to ask.

Regards,
Dimitar
Progress Telerik
Try our brand new, jQuery-free Angular components built from ground-up which deliver the business app essential building blocks - a grid component, data visualization (charts) and form elements.
Tags
GridView
Asked by
Curtis
Top achievements
Rank 1
Iron
Iron
Veteran
Answers by
Curtis
Top achievements
Rank 1
Iron
Iron
Veteran
Dimitar
Telerik team
Share this question
or