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
275
MaskInput is not working
posted

Hello All,

I'm using the bellow code in Initialize Layout to display a mask i.e. ###-###-#### in phone number column but that doesn't seems to work:

 e.Layout.Bands[0].Columns["phoneNumber"].MaskInput = "###-###-####";

 e.Layout.Bands[0].Columns["phoneNumber"].MaskDataMode =  Infragistics.Win.UltraWinMaskedEdit.MaskMode.Raw;

e.Layout.Bands[0].Columns["phoneNumber"].MaskClipMode = Infragistics.Win.UltraWinMaskedEdit.MaskMode.IncludeLiterals;

e.Layout.Bands[0].Columns["phoneNumber"].MaskDisplayMode = Infragistics.Win.UltraWinMaskedEdit.MaskMode.IncludeBoth;

What's wrong with it?

Parents
No Data
Reply
  • 69832
    Verified Answer
    Offline posted

    If the data type of the phone number is string, I think it uses a text editor by default, in which case you would have to explicitly set the Editor property to an Infragistics.Win.EditorWithMask. Come to think of it, I'm not even certain you can use masking with string data.

Children