How I do for add headers to every column of combobox template?

2 posts, 0 answers
  1. kronnos_indigo
    kronnos_indigo avatar
    61 posts
    Member since:
    Jul 2006

    Posted 28 Jan 2010 Link to this post


    I have any SVL.combobox with items templates what it contain 4 to 6 columns. How I do for add titles to every column as similar that ASP.RadComboBox?

    <telerikInput:RadComboBox x:Name="rcbTercero" Width="212" MaxDropDownHeight="250" FontFamily="Trebuchet MS" FontSize="10.667"   
                    Background="#FFD6E9F2" IsHighlighted="True" IsReadOnly="True" Height="25" Canvas.Left="145" Canvas.Top="-1" >                 
                    <telerikInput:RadComboBox.ItemTemplate >  
                                <Grid Margin="3,3,3,3" Width="750">  
                       <ColumnDefinition Width="40" />  
                       <ColumnDefinition Width="120" />  
                       <ColumnDefinition Width="100" />  
                       <ColumnDefinition Width="60" />  
                       <ColumnDefinition Width="60" />  
                       <ColumnDefinition Width="100" />  
                       <ColumnDefinition Width="80" />  
                       <ColumnDefinition Width="20" />  
                       <ColumnDefinition Width="40" />  
                       <ColumnDefinition Width="80" />  
                       <ColumnDefinition Width="40" />  
                       <ColumnDefinition Width="40" />  
                       <ColumnDefinition Width="40" />  
                     <TextBlock Grid.Column="0" Foreground="Black" FontFamily="Verdana" FontSize="8" Text="{Binding codPersona}" HorizontalAlignment="Right" Margin="0,0,10,0"/>  
                     <TextBlock Grid.Column="1" Foreground="Black" FontFamily="Verdana" FontSize="8" Text="{Binding RazonSocial}" HorizontalAlignment="Left" Margin="3,0,0,0"/>  
                     <TextBlock Grid.Column="2" Foreground="Black" FontFamily="Verdana" FontSize="8" Text="{Binding Nombre}" HorizontalAlignment="Left" Margin="3,0,0,0"/>  
                     <TextBlock Grid.Column="3" Foreground="Black" FontFamily="Verdana" FontSize="8" Text="{Binding Telefono}" HorizontalAlignment="Left" Margin="3,0,0,0"/>  
                     <TextBlock Grid.Column="4" Foreground="Black" FontFamily="Verdana" FontSize="8" Text="{Binding Direccion}" HorizontalAlignment="Left" Margin="3,0,0,0"/>  
                     <TextBlock Grid.Column="5" Foreground="Black" FontFamily="Verdana" FontSize="8" Text="{Binding numDocIdentificacion}" HorizontalAlignment="Left" Margin="3,0,0,0"/>  
                     <TextBlock Grid.Column="6" Foreground="Black" FontFamily="Verdana" FontSize="8" Text="{Binding Nit}" HorizontalAlignment="Left" Margin="3,0,0,0"/>  
                     <CheckBox Grid.Column="7" Height="20" Width="20" Content="x" IsChecked="{Binding Vigente}" HorizontalAlignment="Left" Margin="3,0,0,0"/>  
                     <TextBlock Grid.Column="8" Foreground="Black" FontFamily="Verdana" FontSize="8" Text="{Binding Celular}" HorizontalAlignment="Left" Margin="3,0,0,0"/>  
                     <TextBlock Grid.Column="9" Foreground="Black" FontFamily="Verdana" FontSize="8" Text="{Binding Abrev}" HorizontalAlignment="Left" Margin="3,0,0,0"/>  
                     <TextBlock Grid.Column="10" Foreground="Black" FontFamily="Verdana" FontSize="8" Text="{Binding Mini}" HorizontalAlignment="Left" Margin="3,0,0,0"/>  
                     <TextBlock Grid.Column="11" Foreground="Black" FontFamily="Verdana" FontSize="8" Text="{Binding PaginaWeb}" HorizontalAlignment="Left" Margin="3,0,0,0"/>  
                     <TextBlock Grid.Column="12" Foreground="Black" FontFamily="Verdana" FontSize="8" Text="{Binding eMail}" HorizontalAlignment="Left" Margin="3,0,0,0"/>  
                                     <TextBlock Grid.Column="11" Visibility="Collapsed" Text="{Binding FactorDstoCliente}" />  
                     <TextBlock Grid.Column="12" Visibility="Collapsed" Text="{Binding FactorDstoProv}" />  

    Juan Pablo
  2. Konstantina
    Konstantina avatar
    2332 posts

    Posted 01 Feb 2010 Link to this post


    Thank you for contacting us.

    To put a header in a ComboBox will be very hard. However, I can suggest using a DropDownButton instead. Attached you will find a sample project in which in a DropDownButton is added a GridView. That will give you also the rich functionality of the GridView control. You can find more information about the DropDownButton in this demo.

    If you have further questions please feel free to contact us again.

    the Telerik team

    Instantly find answers to your questions on the new Telerik Support Portal.
    Watch a video on how to optimize your support resource searches and check out more tips on the blogs.
  3. DevCraft R3 2016 release webinar banner
Back to Top