Mask in FlatEdit control |
Post Reply |
Author | |
DataCrypt
Groupie Joined: 09 January 2009 Status: Offline Points: 13 |
Post Options
Thanks(0)
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 |
|
Oleg
Admin Group Joined: 21 May 2003 Location: United States Status: Offline Points: 11234 |
Post Options
Thanks(0)
|
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 |
|
DataCrypt
Groupie Joined: 09 January 2009 Status: Offline Points: 13 |
Post Options
Thanks(0)
|
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 |
|
DataCrypt
Groupie Joined: 09 January 2009 Status: Offline Points: 13 |
Post Options
Thanks(0)
|
Hi oleg. Have you verified this? I was wondering if this fix would be available in the next release. Thank you.
Best Regards, DataCrypt |
|
Oleg
Admin Group Joined: 21 May 2003 Location: United States Status: Offline Points: 11234 |
Post Options
Thanks(0)
|
Hello,
Sorry, I don't see something to fix. Its designed behavior.
|
|
Oleg, Support Team
CODEJOCK SOFTWARE SOLUTIONS |
|
DataCrypt
Groupie Joined: 09 January 2009 Status: Offline Points: 13 |
Post Options
Thanks(0)
|
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 |
|
Post Reply | |
Tweet
|
Forum Jump | Forum Permissions You cannot post new topics in this forum You cannot reply to topics in this forum You cannot delete your posts in this forum You cannot edit your posts in this forum You cannot create polls in this forum You cannot vote in polls in this forum |