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

How to Hide Week Number in GridDateTimeColumn

1 Answer 93 Views
Grid
This is a migrated thread and some comments may be shown as answers.
Muthu
Top achievements
Rank 1
Muthu asked on 21 Jul 2020, 07:57 AM

 

   Hi, 

        I want to Hide a Week Number in GridDateTimeColumn. I dont know how to do this. Is there any property to hide this. Please let me know if any solution for this.

 

 

Thanks,

muthukumar c

1 Answer, 1 is accepted

Sort by
0
Doncho
Telerik team
answered on 23 Jul 2020, 11:17 AM

Hi Muthu,

I would assume you want to hide the Week number in the DatePicker which is loaded when the GridDateTime field gets in edit mode.

If this is the case, you need to reference the DatePicker Control and its embedded Calendar to set the ShowRowHeaders=false.

You could use GridTemplateControl instead of GridDateTimeColumn, that way you will be more flexible in customizing the embedded controls declaratively.

For example:

<telerik:GridDateTimeColumn DataField="OrderDate" DataType="System.DateTime" HeaderText="OrderDate" PickerType="DatePicker" UniqueName="OrderDate">
</telerik:GridDateTimeColumn>

Can be replaced with
<telerik:GridTemplateColumn HeaderText="Template" UniqueName="OrderDateTemplate">
    <ItemTemplate>
        <%# Eval("OrderDate") %>
    </ItemTemplate>
    <EditItemTemplate>
        <telerik:RadDatePicker ID="RadDatePicker1" runat="server" dbSelectedDate='<%# Bind("OrderDate") %>'>
            <Calendar runat="server" ShowRowHeaders="false"></Calendar>
        </telerik:RadDatePicker>
    </EditItemTemplate>
</telerik:GridTemplateColumn>
Here are some related resources you may find useful:

I hope that will help you achieve the desired behavior.

Kind regards,
Doncho
Progress Telerik

Tags
Grid
Asked by
Muthu
Top achievements
Rank 1
Answers by
Doncho
Telerik team
Share this question
or