Codejock Forums Homepage
Forum Home Forum Home > Codejock Products > ActiveX COM > General Discussion
  New Posts New Posts RSS Feed - Mask in FlatEdit control
  FAQ FAQ  Forum Search   Events   Register Register  Login Login

Mask in FlatEdit control

 Post Reply Post Reply
Author
Message
DataCrypt View Drop Down
Groupie
Groupie


Joined: 09 January 2009
Status: Offline
Points: 13
Post Options Post Options   Thanks (0) Thanks(0)   Quote DataCrypt Quote  Post ReplyReply Direct Link To This Post Topic: Mask in FlatEdit control
    Posted: 23 February 2011 at 6:48pm
CodeJock Support,

I'm in the process of evaluating your CodeJock Xtreme Suite controls and have a couple of questions regarding the FlatEdit control.  I would like to use (purchase) these controls to use on an older Visual Basic 6 application.  That application uses MaskEdit controls quite a bit and I was trying to replace it with the FlatEdit control.  This requires me to use the SetMask method of the FlatEdit, which is fine, but I have no way of "retrieving" the mask that has been set.

Is there a property or something that will give me the mask that has been set (i.e. FlatEdit1.GetMask)?  If not, would you please consider adding something like this to your control?

Also, when I do set a mask with the default prompt character (an underscore "_") to something like FlatEdit1.SetMask "000-0000", "___-____" (to hold some formatted number with a dash), I seem to have some issues retrieving the data entered from the control.  For example, if not all values are required, and the user enters "123-12" and I output FlatEdit1.Text or FlatEdit1.MaskedText, I get "123-12__".  I am getting the prompt characters in my value.  I want/need the actual data and NOT include the prompt.  What am I doing wrong here?  Not sure if this is a feature or a bug, but it would be nice to request the data in the control without the mask (pure data).

Thank you very much for your time,

DataCrypt
Back to Top
Oleg View Drop Down
Admin Group
Admin Group


Joined: 21 May 2003
Location: United States
Status: Offline
Points: 11234
Post Options Post Options   Thanks (0) Thanks(0)   Quote Oleg Quote  Post ReplyReply Direct Link To This Post Posted: 24 February 2011 at 1:22am
Hi,

MaskedText should return it without '-'  when user will enter all characters.

if you allow only part of text you can set such mask
FlatEdit1.SetMask "000-0000", "   -    ", " "
Oleg, Support Team
CODEJOCK SOFTWARE SOLUTIONS
Back to Top
DataCrypt View Drop Down
Groupie
Groupie


Joined: 09 January 2009
Status: Offline
Points: 13
Post Options Post Options   Thanks (0) Thanks(0)   Quote DataCrypt Quote  Post ReplyReply Direct Link To This Post Posted: 24 February 2011 at 12:24pm
Yes, you are correct - I made a mistake in my original post - it does return it without the "-", but it does return the unfilled prompt character locations.  I don't think it should do that.

So if the mask is "000-0000", "___-____" and the user enters "000-12", MaskedText property should return "00012" and not "0012__".  I think this makes much more sense.  Is there any possibility of the MaskedText changing to return just the data not return the prompt character?

I will try your example mask you provided, but I notice you are not using a prompt char which I would like to display to the user so they can better see what is expected to be entered.

Thank you very much,

DataCrypt
Back to Top
DataCrypt View Drop Down
Groupie
Groupie


Joined: 09 January 2009
Status: Offline
Points: 13
Post Options Post Options   Thanks (0) Thanks(0)   Quote DataCrypt Quote  Post ReplyReply Direct Link To This Post Posted: 20 April 2011 at 9:20am
Hi oleg.  Have you verified this?  I was wondering if this fix would be available in the next release.  Thank you.

Best Regards,

DataCrypt
Back to Top
Oleg View Drop Down
Admin Group
Admin Group


Joined: 21 May 2003
Location: United States
Status: Offline
Points: 11234
Post Options Post Options   Thanks (0) Thanks(0)   Quote Oleg Quote  Post ReplyReply Direct Link To This Post Posted: 21 April 2011 at 1:00am
Hello,

Sorry, I don't see something to fix. Its designed behavior.
Oleg, Support Team
CODEJOCK SOFTWARE SOLUTIONS
Back to Top
DataCrypt View Drop Down
Groupie
Groupie


Joined: 09 January 2009
Status: Offline
Points: 13
Post Options Post Options   Thanks (0) Thanks(0)   Quote DataCrypt Quote  Post ReplyReply Direct Link To This Post Posted: 22 April 2011 at 9:14am
oleg,

In the MaskEdit if not all values are required, and the user enters "123-12" (for a Mask set as "000-0000", "___-____") and I output the MaskedText, I get "123-12__".  Basically it's outputting the prompt characters in my return value.

How can this be a good design?  I need the actual data NOT including the prompt character.  It would be much better to return the text without the mask (pure data) for the MaskedText property. Currently I'm having to go an extra step and manually strip the prompt character!!  This should not be necessary.  The only time I get the pure data and without containing the prompt character is if the text completely fills the mask.

Please re-evaluate this and let me know your thoughts.  Thank you.

Best Regards,

DataCrypt
Back to Top
 Post Reply Post Reply
  Share Topic   

Forum Jump Forum Permissions View Drop Down

Forum Software by Web Wiz Forums® version 12.04
Copyright ©2001-2021 Web Wiz Ltd.

This page was generated in 0.203 seconds.