<?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: Specific data validation with text box</title><link>https://www.infopathdev.com:443/forums/thread/96107.aspx</link><pubDate>Tue, 25 Feb 2014 15:39:33 GMT</pubDate><guid isPermaLink="false">033a2e2d-04e2-4a9d-be01-a4634161eefd:96107</guid><dc:creator>JeffVojtko</dc:creator><slash:comments>0</slash:comments><comments>https://www.infopathdev.com:443/forums/thread/96107.aspx</comments><wfw:commentRss>https://www.infopathdev.com:443/forums/commentrss.aspx?SectionID=41&amp;PostID=96107</wfw:commentRss><description>I have a business user who would like to do string validation on a text box in an InfoPath form. And, the validation requirements are more complex than I can understand being a newbie at this. I was thinking about using some sort of a template or format. Anybody have any ideas?&lt;br /&gt;DSN FIELD: Validation rules:&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;br /&gt;DSN cannot be longer than 44 characters- This is easy&lt;br /&gt;&lt;br /&gt;If possible:&lt;br /&gt;Character 1 must be ‘P’&amp;nbsp; ‘A’&amp;nbsp; or&amp;nbsp; ‘Q’&lt;br /&gt;Characters 6 thru 8 must be ‘SPM’ &lt;br /&gt;Character 9 must be a ‘.’&lt;br /&gt;Characters 14 thru 16 must be numeric&lt;br /&gt;Character 17 must be an ‘S’&lt;br /&gt;</description></item><item><title>Re: Specific data validation with text box</title><link>https://www.infopathdev.com:443/forums/thread/85057.aspx</link><pubDate>Tue, 04 Dec 2012 17:59:01 GMT</pubDate><guid isPermaLink="false">033a2e2d-04e2-4a9d-be01-a4634161eefd:85057</guid><dc:creator>Pasu</dc:creator><slash:comments>0</slash:comments><comments>https://www.infopathdev.com:443/forums/thread/85057.aspx</comments><wfw:commentRss>https://www.infopathdev.com:443/forums/commentrss.aspx?SectionID=41&amp;PostID=85057</wfw:commentRss><description>&lt;blockquote&gt;&lt;p&gt;&amp;nbsp;Hilary, I am still on version 3.4 and will try your solution when I upgrade to 4.2 or greater.&lt;/p&gt;&lt;/blockquote&gt;&lt;blockquote&gt;&lt;p&gt;&amp;nbsp;Jimmy, I replaced the existing condition with that of yours. It works great!&lt;/p&gt;&lt;/blockquote&gt;&lt;p&gt;Thank you both!&lt;br /&gt;&lt;/p&gt;</description></item><item><title>Re: Specific data validation with text box</title><link>https://www.infopathdev.com:443/forums/thread/84940.aspx</link><pubDate>Fri, 30 Nov 2012 15:11:07 GMT</pubDate><guid isPermaLink="false">033a2e2d-04e2-4a9d-be01-a4634161eefd:84940</guid><dc:creator>Hilary Stoupa</dc:creator><slash:comments>0</slash:comments><comments>https://www.infopathdev.com:443/forums/thread/84940.aspx</comments><wfw:commentRss>https://www.infopathdev.com:443/forums/commentrss.aspx?SectionID=41&amp;PostID=84940</wfw:commentRss><description>Jimmy - you rock. I thought there would be a way to do this in a formula, but could not, for the life of me, figure it out. That is a very elegant solution! Thanks for chiming in!</description></item><item><title>Re: Specific data validation with text box</title><link>https://www.infopathdev.com:443/forums/thread/84939.aspx</link><pubDate>Fri, 30 Nov 2012 15:06:17 GMT</pubDate><guid isPermaLink="false">033a2e2d-04e2-4a9d-be01-a4634161eefd:84939</guid><dc:creator>Jimmy</dc:creator><slash:comments>0</slash:comments><comments>https://www.infopathdev.com:443/forums/thread/84939.aspx</comments><wfw:commentRss>https://www.infopathdev.com:443/forums/commentrss.aspx?SectionID=41&amp;PostID=84939</wfw:commentRss><description>&lt;p&gt;You could also use this condition to check whether a field contains any of the characters you&amp;#39;re checking for:&lt;/p&gt;&lt;blockquote&gt;&lt;p&gt;&lt;strong&gt;&lt;u&gt;Field&lt;/u&gt;&lt;/strong&gt; != translate(&lt;u&gt;&lt;strong&gt;Field&lt;/strong&gt;&lt;/u&gt;, &amp;#39;^\:*?&amp;quot;&amp;lt;&amp;gt;|#{}%~&amp;amp;&amp;#39;, &amp;quot;&amp;quot;)&lt;/p&gt;&lt;/blockquote&gt;</description></item><item><title>Re: Specific data validation with text box</title><link>https://www.infopathdev.com:443/forums/thread/84920.aspx</link><pubDate>Fri, 30 Nov 2012 02:24:37 GMT</pubDate><guid isPermaLink="false">033a2e2d-04e2-4a9d-be01-a4634161eefd:84920</guid><dc:creator>Hilary Stoupa</dc:creator><slash:comments>0</slash:comments><comments>https://www.infopathdev.com:443/forums/thread/84920.aspx</comments><wfw:commentRss>https://www.infopathdev.com:443/forums/commentrss.aspx?SectionID=41&amp;PostID=84920</wfw:commentRss><description>&lt;p&gt;Well, I don&amp;#39;t have anything that seems to do any good with custom pattern function in IP. However, I do have something you can do using qRules - what version are you using? This is using the ReplaceString command, that I think I added in v 4.2....&lt;/p&gt;&lt;p&gt;You&amp;#39;d have to store your Result from GetAttachmentAttribute in another field - I&amp;#39;m just using a main data source field, but you could use a 2ds and include the dsnamesrc param:&lt;/p&gt;&lt;p&gt;ReplaceString /xpathsrc=/my:myFields/my:field1 /pattern=[^\\ / : * ? &amp;quot; &amp;lt; &amp;gt; | # { } % ~ &amp;amp;]&lt;/p&gt;&lt;p&gt;If the command returns anything to the Result field, you have one of the special chars listed....&lt;/p&gt;</description></item><item><title>Re: Specific data validation with text box</title><link>https://www.infopathdev.com:443/forums/thread/84910.aspx</link><pubDate>Thu, 29 Nov 2012 21:47:11 GMT</pubDate><guid isPermaLink="false">033a2e2d-04e2-4a9d-be01-a4634161eefd:84910</guid><dc:creator>Pasu</dc:creator><slash:comments>0</slash:comments><comments>https://www.infopathdev.com:443/forums/thread/84910.aspx</comments><wfw:commentRss>https://www.infopathdev.com:443/forums/commentrss.aspx?SectionID=41&amp;PostID=84910</wfw:commentRss><description>&lt;p&gt;&amp;nbsp;Thanks Hilary. For now, I am using the following expression to validate the filename of an attachment. But, if there is a better way, I would like to adapt that.&lt;/p&gt;&lt;blockquote&gt;&lt;p&gt;&lt;img src="http://i.minus.com/iREnc4O1QHCac.jpg" title="The expression..." alt="The expression..." height="242" width="492" /&gt;&amp;nbsp;&lt;/p&gt;&lt;/blockquote&gt;</description></item><item><title>Re: Specific data validation with text box</title><link>https://www.infopathdev.com:443/forums/thread/84897.aspx</link><pubDate>Thu, 29 Nov 2012 17:37:32 GMT</pubDate><guid isPermaLink="false">033a2e2d-04e2-4a9d-be01-a4634161eefd:84897</guid><dc:creator>Hilary Stoupa</dc:creator><slash:comments>0</slash:comments><comments>https://www.infopathdev.com:443/forums/thread/84897.aspx</comments><wfw:commentRss>https://www.infopathdev.com:443/forums/commentrss.aspx?SectionID=41&amp;PostID=84897</wfw:commentRss><description>That&amp;#39;s what I get for testing my regular expression outside of InfoPath.... I&amp;#39;ll take a look later today &amp;amp; see if I can come up with something that will work for you.</description></item><item><title>Re: Specific data validation with text box</title><link>https://www.infopathdev.com:443/forums/thread/84893.aspx</link><pubDate>Thu, 29 Nov 2012 17:12:06 GMT</pubDate><guid isPermaLink="false">033a2e2d-04e2-4a9d-be01-a4634161eefd:84893</guid><dc:creator>Pasu</dc:creator><slash:comments>0</slash:comments><comments>https://www.infopathdev.com:443/forums/thread/84893.aspx</comments><wfw:commentRss>https://www.infopathdev.com:443/forums/commentrss.aspx?SectionID=41&amp;PostID=84893</wfw:commentRss><description>&lt;p&gt;Thanks Hilary. I tried the following, but got invalid pattern error.&lt;br /&gt;&lt;/p&gt;&lt;blockquote&gt;&lt;p&gt;&lt;img src="http://i.minus.com/iw8MybEnGbpdY.jpg" title="Rule" alt="Rule" /&gt;&amp;nbsp;&lt;/p&gt;&lt;/blockquote&gt;&lt;blockquote&gt;&lt;p&gt;&lt;img src="http://i.minus.com/iBsYa2NxreTch.jpg" title="Condition" alt="Condition" /&gt;&amp;nbsp;&lt;/p&gt;&lt;/blockquote&gt;&lt;blockquote&gt;&lt;p&gt;&lt;img src="http://i.minus.com/iSNTN29A6BSdi.jpg" title="Data Entry Pattern" alt="Data Entry Pattern" height="276" width="300" /&gt;&lt;/p&gt;&lt;/blockquote&gt;&lt;blockquote&gt;&lt;p&gt;&amp;nbsp;&lt;img src="http://i.minus.com/ibwzYk9F8ML8JQ.jpg" title="Invalid Pattern Error" alt="Invalid Pattern Error" height="111" width="251" /&gt;&lt;/p&gt;&lt;/blockquote&gt;&lt;p&gt;Any help is appreciated.&lt;/p&gt;&lt;p&gt;Thanks!!&lt;br /&gt;&lt;/p&gt;</description></item><item><title>Re: Specific data validation with text box</title><link>https://www.infopathdev.com:443/forums/thread/84475.aspx</link><pubDate>Fri, 16 Nov 2012 01:16:19 GMT</pubDate><guid isPermaLink="false">033a2e2d-04e2-4a9d-be01-a4634161eefd:84475</guid><dc:creator>Hilary Stoupa</dc:creator><slash:comments>0</slash:comments><comments>https://www.infopathdev.com:443/forums/thread/84475.aspx</comments><wfw:commentRss>https://www.infopathdev.com:443/forums/commentrss.aspx?SectionID=41&amp;PostID=84475</wfw:commentRss><description>&lt;p&gt;Yes, you should be able to do this. I think this pattern would work:&lt;/p&gt;&lt;p&gt;[^\\ / : * ? &amp;quot; &amp;lt; &amp;gt; | # { } % ~ &amp;amp;]&lt;/p&gt;&lt;p&gt;So, you&amp;#39;d run your rule for GetAttachmentAttribute, then add another rule with a condition that the qRules data source Result node matches this pattern, and you could then clear the node where they attached the file or give them a message or some such....&lt;/p&gt;</description></item><item><title>Re: Specific data validation with text box</title><link>https://www.infopathdev.com:443/forums/thread/84470.aspx</link><pubDate>Thu, 15 Nov 2012 19:42:33 GMT</pubDate><guid isPermaLink="false">033a2e2d-04e2-4a9d-be01-a4634161eefd:84470</guid><dc:creator>Pasu</dc:creator><slash:comments>0</slash:comments><comments>https://www.infopathdev.com:443/forums/thread/84470.aspx</comments><wfw:commentRss>https://www.infopathdev.com:443/forums/commentrss.aspx?SectionID=41&amp;PostID=84470</wfw:commentRss><description>&lt;p&gt; I am using &lt;u&gt;SaveToSharePoint&lt;/u&gt; qRules method to save InfoPath attachments in a SharePoint document library. When we try to attach files with illegal filename characters (&lt;span style="COLOR:red;" id="ctl00_PlaceHolderMain_ctl01_ctl02_ctl01"&gt;\ / : * ? &amp;quot; &amp;lt; &amp;gt; | # { } % ~ &amp;amp;&lt;/span&gt;), the &lt;u&gt;SaveToSharePoint&lt;/u&gt; method succeeds but cutting off all characters after the first occurence of the illegal character. That leaves the residue in tha document library, with a broken link inside Infopath. To avoid users uploading a file with illegal character, I am trying to validate the filename of an attachment, using the &lt;u&gt;GetAttachmentAttribute&lt;/u&gt; qRules method. Is it possible to validate the result of the &lt;u&gt;GetAttachmentAttribute&lt;/u&gt; method to check whether it contains any of the illegal characters, using a pattern?&lt;/p&gt;&lt;p&gt;Thanks a lot in advance.&lt;br /&gt;&lt;/p&gt;</description></item><item><title>Re: Specific data validation with text box</title><link>https://www.infopathdev.com:443/forums/thread/51472.aspx</link><pubDate>Sat, 06 Feb 2010 10:16:28 GMT</pubDate><guid isPermaLink="false">033a2e2d-04e2-4a9d-be01-a4634161eefd:51472</guid><dc:creator>Jimmy</dc:creator><slash:comments>0</slash:comments><comments>https://www.infopathdev.com:443/forums/thread/51472.aspx</comments><wfw:commentRss>https://www.infopathdev.com:443/forums/commentrss.aspx?SectionID=41&amp;PostID=51472</wfw:commentRss><description>&lt;p&gt;&amp;nbsp;I also don&amp;#39;t understand why you would suggest using a separate textbox to perform this validation.&amp;nbsp; That would give the user a confusing textbox with all the spaces converted to &lt;b&gt;a&lt;/b&gt;s.&lt;/p&gt;&lt;p&gt;This pattern should work:&lt;/p&gt;&lt;blockquote&gt;&lt;p&gt;[a-zA-Z]([ ]*[a-zA-Z])*&lt;/p&gt;&lt;/blockquote&gt;&lt;p&gt;The pattern above will approve strings that meet all of the following criteria:&lt;/p&gt;&lt;blockquote&gt;&lt;p&gt;Contains one or more letters&lt;br /&gt;&lt;/p&gt;&lt;p&gt;Contains 0 or more spaces&lt;/p&gt;&lt;p&gt;Begins and ends with a letter&lt;/p&gt;&lt;p&gt;Contains no characters that are not letters or spaces&lt;/p&gt;&lt;/blockquote&gt;&lt;p&gt;I know you didn&amp;#39;t mention the third criterion, but I would imagine that&amp;#39;s what you want.&amp;nbsp; If you don&amp;#39;t mind spaces at the beginning and end but still want to require at least one letter, you can use this pattern:&lt;/p&gt;&lt;blockquote&gt;&lt;p&gt;[ ]*[a-zA-Z][a-zA-Z ]* &lt;br /&gt;&lt;/p&gt;&lt;/blockquote&gt;</description></item><item><title>Re: Specific data validation with text box</title><link>https://www.infopathdev.com:443/forums/thread/50392.aspx</link><pubDate>Thu, 07 Jan 2010 16:02:03 GMT</pubDate><guid isPermaLink="false">033a2e2d-04e2-4a9d-be01-a4634161eefd:50392</guid><dc:creator>Qazi Anis</dc:creator><slash:comments>0</slash:comments><comments>https://www.infopathdev.com:443/forums/thread/50392.aspx</comments><wfw:commentRss>https://www.infopathdev.com:443/forums/commentrss.aspx?SectionID=41&amp;PostID=50392</wfw:commentRss><description>&lt;p&gt;also one thing &amp;quot; &amp;quot; this is space not a blank&lt;/p&gt;</description></item><item><title>Re: Specific data validation with text box</title><link>https://www.infopathdev.com:443/forums/thread/50391.aspx</link><pubDate>Thu, 07 Jan 2010 16:00:20 GMT</pubDate><guid isPermaLink="false">033a2e2d-04e2-4a9d-be01-a4634161eefd:50391</guid><dc:creator>Qazi Anis</dc:creator><slash:comments>0</slash:comments><comments>https://www.infopathdev.com:443/forums/thread/50391.aspx</comments><wfw:commentRss>https://www.infopathdev.com:443/forums/commentrss.aspx?SectionID=41&amp;PostID=50391</wfw:commentRss><description>&lt;p&gt;hi,&lt;/p&gt;
&lt;p&gt;well if you check properly, &lt;/p&gt;
&lt;p&gt;i am setting value of second text box to value of first text box - spaces and alphas &lt;/p&gt;
&lt;p&gt;i am validating second text box based on the validation of first text box.&lt;/p&gt;
&lt;p&gt;give it a shot &lt;/p&gt;</description></item><item><title>Re: Specific data validation with text box</title><link>https://www.infopathdev.com:443/forums/thread/50382.aspx</link><pubDate>Thu, 07 Jan 2010 13:10:20 GMT</pubDate><guid isPermaLink="false">033a2e2d-04e2-4a9d-be01-a4634161eefd:50382</guid><dc:creator>harasgalt</dc:creator><slash:comments>0</slash:comments><comments>https://www.infopathdev.com:443/forums/thread/50382.aspx</comments><wfw:commentRss>https://www.infopathdev.com:443/forums/commentrss.aspx?SectionID=41&amp;PostID=50382</wfw:commentRss><description>&lt;p&gt;&amp;nbsp;The pattern does not take into account spaces.&lt;/p&gt;&lt;p&gt;&amp;nbsp;However the alpha words are fine but as soon as i put in trailing and leading spaces it generates a validation error.&lt;/p&gt;&lt;p&gt;&amp;nbsp;&lt;/p&gt;&lt;p&gt;&amp;nbsp;&lt;/p&gt;</description></item><item><title>Re: Specific data validation with text box</title><link>https://www.infopathdev.com:443/forums/thread/50381.aspx</link><pubDate>Thu, 07 Jan 2010 13:07:25 GMT</pubDate><guid isPermaLink="false">033a2e2d-04e2-4a9d-be01-a4634161eefd:50381</guid><dc:creator>harasgalt</dc:creator><slash:comments>0</slash:comments><comments>https://www.infopathdev.com:443/forums/thread/50381.aspx</comments><wfw:commentRss>https://www.infopathdev.com:443/forums/commentrss.aspx?SectionID=41&amp;PostID=50381</wfw:commentRss><description>&lt;p&gt;&amp;nbsp;I tried your pattern without the second text box, it seems to work ?&lt;/p&gt;&lt;p&gt;I&amp;#39;ll have to do further testing but thank you very much. &lt;br /&gt;&lt;/p&gt;</description></item></channel></rss>