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

GridDateTimeColumn Icon not showing

1 Answer 79 Views
Grid
This is a migrated thread and some comments may be shown as answers.
Phil H.
Top achievements
Rank 2
Phil H. asked on 15 Sep 2016, 05:28 PM

Hi:

 

This not a question, but an answer.

<Telerik:GridDateTimeColumn DataField="SampleTime" UniqueName="SampleTimeColumn" HeaderText="Time" HeaderStyle-Width="90px" ItemStyle-Width="86px" DataType="System.DateTime" PickerType="TimePicker">
</Telerik:GridDateTimeColumn>

The problem is the width of 90px does not allow for the full display of the date-time picker, so in code behind:

WebControl _timeGridControl = _item["SampleTimeColumn"];
if (_timeGridControl.Controls.Count > 0)
{
    RadTimePicker _timeTextBox = (RadTimePicker)_timeGridControl.Controls[0];
    _timeTextBox.Width = new Unit("80px");
      _timeTextBox.DateInput.DisplayDateFormat = "HH:mm";
      _timeTextBox.DateInput.DateFormat = "HH:mm";
}

Phil

1 Answer, 1 is accepted

Sort by
0
Eyup
Telerik team
answered on 20 Sep 2016, 05:16 AM
Hi Phil,

Thank you for sharing your approach with your community. I hope it helps other developers as well.
Generally, there is also the following property, which may prove helpful:
<telerik:GridDateTimeColumn ... FilterControlWidth="70px">

Regards,
Eyup
Telerik by Progress
Do you need help with upgrading your ASP.NET AJAX, WPF or WinForms projects? Check the Telerik API Analyzer and share your thoughts.
Tags
Grid
Asked by
Phil H.
Top achievements
Rank 2
Answers by
Eyup
Telerik team
Share this question
or