<?xml version="1.0" encoding="UTF-8" ?>
<?xml-stylesheet type="text/xsl" href="https://www.infopathdev.com:443/utility/FeedStylesheets/rss.xsl" media="screen"?><rss version="2.0" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:slash="http://purl.org/rss/1.0/modules/slash/" xmlns:wfw="http://wellformedweb.org/CommentAPI/"><channel><title>General</title><link>https://www.infopathdev.com:443/forums/41.aspx</link><description>If you're not sure where to ask your question, ask it here. If necessary, our moderators will make sure it gets classified in the correct board.</description><dc:language>en</dc:language><generator>CommunityServer 2007 SP3 (Build: 31118.962)</generator><item><title>Re: Pattern Matches for Decimal and Zero Value</title><link>https://www.infopathdev.com:443/forums/thread/106245.aspx</link><pubDate>Tue, 19 Apr 2016 14:54:55 GMT</pubDate><guid isPermaLink="false">033a2e2d-04e2-4a9d-be01-a4634161eefd:106245</guid><dc:creator>Hilary Stoupa</dc:creator><slash:comments>0</slash:comments><comments>https://www.infopathdev.com:443/forums/thread/106245.aspx</comments><wfw:commentRss>https://www.infopathdev.com:443/forums/commentrss.aspx?SectionID=41&amp;PostID=106245</wfw:commentRss><description>Thanks for updating with your final working solution, Gwen! :)</description></item><item><title>Re: Pattern Matches for Decimal and Zero Value</title><link>https://www.infopathdev.com:443/forums/thread/106244.aspx</link><pubDate>Tue, 19 Apr 2016 14:39:19 GMT</pubDate><guid isPermaLink="false">033a2e2d-04e2-4a9d-be01-a4634161eefd:106244</guid><dc:creator>GwenW</dc:creator><slash:comments>0</slash:comments><comments>https://www.infopathdev.com:443/forums/thread/106244.aspx</comments><wfw:commentRss>https://www.infopathdev.com:443/forums/commentrss.aspx?SectionID=41&amp;PostID=106244</wfw:commentRss><description>&lt;p&gt;For reference on pattern matching with decimals&amp;nbsp;(in case anyone is looking for this)... I ended up using a string field with the following&amp;nbsp;pattern match:&lt;/p&gt;&lt;p&gt;&amp;nbsp;\-?\d+\.?\d{0,3}&lt;/p&gt;&lt;p&gt;This allows any negative or non-negative whole number or decimal (up to 3&amp;nbsp;places). &lt;/p&gt;&lt;p&gt;&amp;nbsp;Originally I tried &amp;nbsp; \-?\d*\.?\d{0,3} but this allowed a negative sign to be a valid value (no numbers) because the * means any number of digits (including zero).&lt;/p&gt;&lt;p&gt;&amp;nbsp;&lt;/p&gt;</description></item><item><title>Re: Pattern Matches for Decimal and Zero Value</title><link>https://www.infopathdev.com:443/forums/thread/106221.aspx</link><pubDate>Mon, 18 Apr 2016 14:03:48 GMT</pubDate><guid isPermaLink="false">033a2e2d-04e2-4a9d-be01-a4634161eefd:106221</guid><dc:creator>GwenW</dc:creator><slash:comments>0</slash:comments><comments>https://www.infopathdev.com:443/forums/thread/106221.aspx</comments><wfw:commentRss>https://www.infopathdev.com:443/forums/commentrss.aspx?SectionID=41&amp;PostID=106221</wfw:commentRss><description>&lt;p&gt;Thanks,&amp;nbsp;Patrick! I&amp;#39;ll give that a try.&amp;nbsp;&lt;/p&gt;</description></item><item><title>Re: Pattern Matches for Decimal and Zero Value</title><link>https://www.infopathdev.com:443/forums/thread/106207.aspx</link><pubDate>Mon, 18 Apr 2016 12:29:13 GMT</pubDate><guid isPermaLink="false">033a2e2d-04e2-4a9d-be01-a4634161eefd:106207</guid><dc:creator>Patrick Halstead</dc:creator><slash:comments>0</slash:comments><comments>https://www.infopathdev.com:443/forums/thread/106207.aspx</comments><wfw:commentRss>https://www.infopathdev.com:443/forums/commentrss.aspx?SectionID=41&amp;PostID=106207</wfw:commentRss><description>&lt;p&gt;Hi Gwen,&lt;/p&gt;&lt;p&gt;My first guess is that pattern&amp;nbsp;matching validation only works on strings. &lt;/p&gt;&lt;p&gt;Can you&amp;nbsp;add a separate string field for your input and set the decimal field when it changes (assuming it matches the value)?&lt;/p&gt;&lt;p&gt;My second guess is that it is getting hung up on the &amp;#39;\.&amp;#39; since the dot has special parsing meaning. But, your slash prefix should take care of that. &lt;/p&gt;&lt;p&gt;You can control the number of items by affixing \d{0,3} which will match a number 0 or 1 or&amp;nbsp;2 or 3 times&amp;nbsp;but not 4 or more.&lt;/p&gt;&lt;p&gt;Hope this helps in some&amp;nbsp;way.&amp;nbsp;&amp;nbsp;&lt;/p&gt;</description></item><item><title>Pattern Matches for Decimal and Zero Value</title><link>https://www.infopathdev.com:443/forums/thread/106187.aspx</link><pubDate>Fri, 15 Apr 2016 19:35:25 GMT</pubDate><guid isPermaLink="false">033a2e2d-04e2-4a9d-be01-a4634161eefd:106187</guid><dc:creator>GwenW</dc:creator><slash:comments>0</slash:comments><comments>https://www.infopathdev.com:443/forums/thread/106187.aspx</comments><wfw:commentRss>https://www.infopathdev.com:443/forums/commentrss.aspx?SectionID=41&amp;PostID=106187</wfw:commentRss><description>&lt;p&gt;Hi, I&amp;#39;m trying a pattern match on a decimal data type. Right now I have the results that I want (any positive or negative decimal number is valid), except that it won&amp;#39;t match 0 (zero), which should be valid.&amp;nbsp; Here is my expression: &lt;font face="Times New Roman" size="3"&gt;

&lt;/font&gt;&lt;/p&gt;&lt;p style="margin:0in 0in 0pt;"&gt;&lt;font face="Calibri" size="3"&gt;-?\d*?\.\d*&lt;/font&gt;&lt;/p&gt;&lt;p&gt;&lt;font face="Times New Roman" size="3"&gt;

The text box containing the decimal (default value is 0.000)&amp;nbsp;is formatted as a percentage with 3 decimal places. So 0 appears as 0.000. Is this what&amp;#39;s throwing off my expression to find 0 (or 0.000) invalid?&amp;nbsp; I have a work around where my rule to has the following condition:&lt;/font&gt;&lt;/p&gt;&lt;p&gt;&amp;nbsp;field matches custom pattern (&lt;font face="Calibri" size="3"&gt;-?\d*?\.\d*) or &lt;strong&gt;field = 0&lt;/strong&gt; &lt;/font&gt;&lt;/p&gt;&lt;p&gt;&amp;nbsp;This works, but&amp;nbsp;&amp;nbsp;I really want to know why the expression itself isn&amp;#39;t working. Everything I&amp;#39;ve found online says it should. (I also tried &lt;font face="Calibri" size="3"&gt;-?\d*\.\d*) and it didn&amp;#39;t work. I don&amp;#39;t have a lot of experience with these, so I may have some obvious issue that I&amp;#39;m not seeing.&lt;/font&gt;&lt;/p&gt;&lt;p&gt;Thanks!&amp;nbsp;Gwen&amp;nbsp;&lt;/p&gt;&lt;p&gt;&amp;nbsp;&lt;/p&gt;</description></item></channel></rss>