On a wingrid I have a few time and date fields I let the user edit.
The thing is that the user needs to type the entire date or the entire time to be assumed as a valid date.
So lets assume that I have this date format:
dd-MM-yyyy
The user needs to the day, month and year. But it would be much more productive to just type the day for instance, and assume current month and year. For example I would type:
5 ->TAB
and the editor would assume 05-05-2012.
if I typed both day and month:
5-6
It would assume the current year 05-06-2012
This seems a small tweak but its in fact a major pain having to input full dates when you are inserting hundreds of records a day manually.
Any tips on how to accomplish this with WinGrid?
Infragistics2.Win.UltraWinGrid.v11.1
version: 11.1.20111.2071
Hello,
What you could do is to assign as an EditorComponent to the Grid column a 'UltraDateTimeEditor' control. Set the 'AutoFillDate' property of the date time editor to 'MonthAndYear', MaskInput to 'dd/mm/yyyy'.
Please feel free to let me know if I misunderstood you or if you have any other questions.
Hi,
Thanks a lot for your tip worked like a charm!
I've tried doing the same with a time field but was not able to make it assume the minutes if I type only the hours. Is that possible? Tried to use the AutoFillTime with a UltraDateTimeEditor but no luck if I want to have 14:00 for example, I need to type at the very least 140. If I want to have 5:00 I need to type 050. What I would like to do is to type 14 +tab and it would assume 14:00. If I typed 5 and tab it would assume 05:00.
if that possible?
Thanks