Your Privacy Matters: We use our own and third-party cookies to improve your experience on our website. By continuing to use the website we understand that you accept their use. Cookie Policy
675
trouble binding XamMaskedEditor with mask to TimeSpan
posted

I've bound the XamMaskedEditor to a TimeSpan property in my class and as long as I use a mask of "hh:mm:ss" it works fine. I'd like to use a mask of "hh:mm tt" instead so that I get a display formatted like this "10:59 PM" but I can't seem to get it working. Could someone take a look at the attached project and give some advice? 

Thanks!

TimeSpanEditor.zip
Parents
No Data
Reply
  • 138253
    Offline posted

    Hello,

     

    Thank you for your post. I have been looking into it and the sample you sent and modified it, so now it works as you want. Basically I set the XamMaskedEditor’s ValueToTextConverter to a Converter where I implemented the ConvertBack method, because the Editor cannot convert the value displayed in it into TimeSpan by itself. Please let me know if this helps you r you need further assistance on this matter.

     

    Looking forward for your reply.

    TimeSpanEditor.zip
Children