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

Display Time in Military Time

4 Answers 115 Views
TimePicker
This is a migrated thread and some comments may be shown as answers.
StevenDale
Top achievements
Rank 2
StevenDale asked on 05 Jun 2009, 05:08 PM
Is it possible to show the times in the RadTimePicker in Military Time format?

Thanks,

Billy Jacobs

4 Answers, 1 is accepted

Sort by
0
StevenDale
Top achievements
Rank 2
answered on 05 Jun 2009, 07:18 PM
I see how to use military time now by setting the starttime and endtime to "0:0:0" and "23:0:0" but how do you set it back programatically?
0
Boyan
Telerik team
answered on 09 Jun 2009, 03:05 PM
Hi Billy ,

You can set the culture by changing the culture of the control. Use this code:
timepicker1.Culture = new CultureInfo("en-gb"); 

This will set the RadTimePicker to military time if you want AM/PM change culture to "en-us".

Hope this helps.

All the best,
Boyan
the Telerik team

Instantly find answers to your questions on the new Telerik Support Portal.
Check out the tips for optimizing your support resource searches.
0
StevenDale
Top achievements
Rank 2
answered on 09 Jun 2009, 09:48 PM
Is there a way to set it in a style based on the value of another control such as a checkbox.

My problem is that my TimePicker is in a datatemplate and I can access is programatically. So if I could use Triggers to set the the Culture property based on whether a checkbox was checked or not would solve my problem.

Thanks,

Billy Jacobs
0
Boyan
Telerik team
answered on 11 Jun 2009, 02:40 PM
Hello Billy Jacobs,

You can do this by using triggers. The solution will be different depending on whether the Checkbox is in the template or not . You can take a look at this article that will give you an idea on how it can be done.
 
If you need more help please let me know.

Best wishes,
Boyan
the Telerik team

Instantly find answers to your questions on the new Telerik Support Portal.
Check out the tips for optimizing your support resource searches.
Tags
TimePicker
Asked by
StevenDale
Top achievements
Rank 2
Answers by
StevenDale
Top achievements
Rank 2
Boyan
Telerik team
Share this question
or