We use cookies to give you the best experience on our website. If you continue to browse, then you agree to our privacy policy and cookie policy. Image for the cookie policy date

DateTimePicker : using the "/" character

Hi! I am using the dateTimePickerAdv in dd/MM/yyyy format.... and auto forwarding mode I would like that the "/" character can be seize (explicit) or not (implicit)... in fact, I want to have the same result if I enter "12122004" and "12/12/2004" Is it possible? Thanks! bye lobrys

3 Replies

AD Administrator Syncfusion Team September 8, 2004 07:41 AM

Hi Lobrys, Could you please clarify if i understood your requirements correctly. 1) You need the behavior of Autoforwarding but do not want the "/" key to forward to the next field. If so here is a sample that shows how you can do that DateTimePickerBackSpaceKey_6144.zip The effect of entering "12122004" and "12/12/2004" would be the same, the "/" characted would be ignored. Please let me know if you have any questions. Thanks. Best regards, Stephen. >Hi! > >I am using the dateTimePickerAdv in dd/MM/yyyy format.... and auto forwarding mode > >I would like that the "/" character can be seize (explicit) or not (implicit)... >in fact, I want to have the same result if I enter "12122004" and "12/12/2004" > >Is it possible? > >Thanks! >bye >lobrys >


LO Lobrys September 9, 2004 02:47 AM

hello thanks for your help! Yes, I use the autoforwarding behavior, but I still want to permit the "/" key to forward Here is some exemple : when enter "12122004", results : 12/12/2004 when enter "12/12/2004", results : 12/12/2004 when enter "1/1/2004", results : 1/1/2004 when enter "01012004", results : 1/1/2004 in fact.... in your sample application, in function ProcessCmdKey, I need to know the value of the current field... if the current value is "1" and the key taped is "/", I forward to the next field if the current value is "1" and the key taped is "1", the new value must be "11" if the current value is "11" and the key taped is "/", I forward to the next field so, is it possible to do this? THANKS!!!!! bye lobrys


LO Lobrys September 9, 2004 03:01 AM

Hi!!! Excuse me! Please ignore the previous message!!!!!!! I said some mistakes! bye lobrys (I am so tired!)

Loader.
Live Chat Icon For mobile
Up arrow icon