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

ListHeader always takes up space

1 Answer 19 Views
DataBoundListBox
This is a migrated thread and some comments may be shown as answers.
This question is locked. New answers and comments are not allowed.
Michiel
Top achievements
Rank 1
Michiel asked on 22 Feb 2012, 04:56 PM
I have a RadDataBoundListBox and sometimes I want to show a header, sometimes not. But when I'm using a Header, without content, or with a stackpanel that is Collapsed, it still takes up space (30 pixels?). Is there a way to work around this?

Example header which can be used in the Telerik example project:

<DataTemplate x:Key="HeaderTemplate">
      <StackPanel Visibility="Collapsed">
          <TextBlock>etc</TextBlock>
     </StackPanel>
</DataTemplate>         

I'm using the Q1 2012 release.

1 Answer, 1 is accepted

Sort by
0
Deyan
Telerik team
answered on 23 Feb 2012, 10:43 AM
Hello Michiel,

Thanks for contacting us.

I have tried to reproduce the issue in a list box with a ListHeaderTemplate defined by setting the Visibility property of the root element of the template to Collapsed but everything works as expected on my side.

Could you please reveale some further details on how you are updating the visibility, whether you are doing this dynamically or you are simply exchanging templates?

A demo project that reproduces the scenario would be the best way for me to investigate the case and further assist you.

Please note that you will have to open a new support ticket in order to be able to attach your project.

Thanks for your time.

Regards,
Deyan
the Telerik team
Sharpen your .NET Ninja skills! Attend Q1 webinar week and get a chance to win a license! Book your seat now >>
Tags
DataBoundListBox
Asked by
Michiel
Top achievements
Rank 1
Answers by
Deyan
Telerik team
Share this question
or