ReportPortal
ReportPortal
Home | Profile | Register | Active Topics | Members | Search | FAQ
Username:
Password:
Save Password
Forgot your Password?

 All Forums
 ReportPortal General Forum
 Report Portal General Issues
 Custom Textbox Mask
 New Topic  Reply to Topic
 Printer Friendly
Author Previous Topic Topic Next Topic  

anavagomez

29 Posts

Posted - 06/28/2012 :  08:05:08  Show Profile  Reply with Quote
Hello,

I would like to ask for some help regarding a custom Textbox Mask.

I need to make sure that the values entered in a few textboxes are numbers in this format:

.0 or .00 or 0.0, or 0.00

I think a regular expression can be used, as a matter of fact I used one when the values are saved from a c# program I wrote and that reg exp looks like:

"^(\\d+)?(\\.\\d*)?$"

Can I use that same Reg Exp in report portal, or what the syntax would be in this case?


Thank you much for your help.

admin

1640 Posts

Posted - 06/28/2012 :  10:57:49  Show Profile  Reply with Quote
Are you talking about Textbox Mask for Data Entry form? It is not using Regular Expression but a third party library called Masked Input (http://jsfromhell.com/forms/masked-input).

Please try: *.9*
Go to Top of Page

anavagomez

29 Posts

Posted - 06/28/2012 :  11:54:49  Show Profile  Reply with Quote
thank you that helps a lot.

i just need to be able to also permit this format:

.0 or .00 or 0.0, or 0.00, or 00.00

thas was my bad, i forgot to include it on my forst post.
Go to Top of Page

anavagomez

29 Posts

Posted - 06/28/2012 :  12:01:54  Show Profile  Reply with Quote
will it be?

*9.9*
Go to Top of Page

admin

1640 Posts

Posted - 06/28/2012 :  19:40:04  Show Profile  Reply with Quote
No, *9.9* would require to digits before the decimal point. In your case it would be the best if you just allow numbers and period like:

9^.
Go to Top of Page
  Previous Topic Topic Next Topic  
 New Topic  Reply to Topic
 Printer Friendly
Jump To:
ReportPortal © 2000-2002 Snitz Communications Go To Top Of Page