<?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: Numeric only fields</title><link>https://www.infopathdev.com:443/forums/thread/109426.aspx</link><pubDate>Tue, 07 Feb 2017 23:29:30 GMT</pubDate><guid isPermaLink="false">033a2e2d-04e2-4a9d-be01-a4634161eefd:109426</guid><dc:creator>dc330</dc:creator><slash:comments>0</slash:comments><comments>https://www.infopathdev.com:443/forums/thread/109426.aspx</comments><wfw:commentRss>https://www.infopathdev.com:443/forums/commentrss.aspx?SectionID=41&amp;PostID=109426</wfw:commentRss><description>Yousa the boss Matt!  That works perfectly!</description></item><item><title>Re: Numeric only fields</title><link>https://www.infopathdev.com:443/forums/thread/34027.aspx</link><pubDate>Sun, 09 Nov 2008 00:30:45 GMT</pubDate><guid isPermaLink="false">033a2e2d-04e2-4a9d-be01-a4634161eefd:34027</guid><dc:creator>sind2008</dc:creator><slash:comments>0</slash:comments><comments>https://www.infopathdev.com:443/forums/thread/34027.aspx</comments><wfw:commentRss>https://www.infopathdev.com:443/forums/commentrss.aspx?SectionID=41&amp;PostID=34027</wfw:commentRss><description>&lt;p&gt;&lt;strong&gt;Hi Abhishek &lt;/strong&gt;&lt;/p&gt;
&lt;p&gt;&lt;strong&gt;I tried the above code in Infopath2003. it is giving me error.&lt;/strong&gt;&lt;/p&gt;
&lt;p&gt;&lt;strong&gt;Suresh &lt;/strong&gt;&lt;/p&gt;</description></item><item><title>Re: Numeric only fields</title><link>https://www.infopathdev.com:443/forums/thread/9038.aspx</link><pubDate>Sat, 11 Feb 2006 03:03:55 GMT</pubDate><guid isPermaLink="false">033a2e2d-04e2-4a9d-be01-a4634161eefd:9038</guid><dc:creator>vista_live</dc:creator><slash:comments>0</slash:comments><comments>https://www.infopathdev.com:443/forums/thread/9038.aspx</comments><wfw:commentRss>https://www.infopathdev.com:443/forums/commentrss.aspx?SectionID=41&amp;PostID=9038</wfw:commentRss><description>Thank you guys :)</description></item><item><title>Re: Numeric only fields</title><link>https://www.infopathdev.com:443/forums/thread/9037.aspx</link><pubDate>Fri, 10 Feb 2006 14:13:42 GMT</pubDate><guid isPermaLink="false">033a2e2d-04e2-4a9d-be01-a4634161eefd:9037</guid><dc:creator>Matt Faus</dc:creator><slash:comments>0</slash:comments><comments>https://www.infopathdev.com:443/forums/thread/9037.aspx</comments><wfw:commentRss>https://www.infopathdev.com:443/forums/commentrss.aspx?SectionID=41&amp;PostID=9037</wfw:commentRss><description>Why write custom code when you can just use the Data validation built in to InfoPath? If a field is invalid, InfoPath can issue a message box on it&amp;#39;s own.&lt;br /&gt;&lt;br /&gt;Try this:&lt;br /&gt;&lt;br /&gt;1. Double-click the field&lt;br /&gt;2. Click Data Validation at the bottom of the dialog box.&lt;br /&gt;3. Click Add&lt;br /&gt;4. Select Does Not Match Pattern from the second drop-down box.&lt;br /&gt;5. Type the following custom pattern into the third drop-down &amp;quot;\d*&amp;quot;.&lt;br /&gt;6. Type the message you want the user to see in the short and detailed error message fields.&lt;br /&gt;7. Select Dialog Box Alert from the drop-down.&lt;br /&gt;8. Click OK three times.&lt;br /&gt;&lt;br /&gt;---------------&lt;br /&gt;Matt Faus&lt;br /&gt;InfoPath Dev Texas</description></item><item><title>Re: Numeric only fields</title><link>https://www.infopathdev.com:443/forums/thread/9036.aspx</link><pubDate>Fri, 10 Feb 2006 06:02:46 GMT</pubDate><guid isPermaLink="false">033a2e2d-04e2-4a9d-be01-a4634161eefd:9036</guid><dc:creator>Abhishek</dc:creator><slash:comments>0</slash:comments><comments>https://www.infopathdev.com:443/forums/thread/9036.aspx</comments><wfw:commentRss>https://www.infopathdev.com:443/forums/commentrss.aspx?SectionID=41&amp;PostID=9036</wfw:commentRss><description>Hi Vista_Live&lt;br /&gt;         I dont think u can restrict users from entering non numeric values into the text box. However u can throw an alert to the user to enter numeric values only by writing code in the OnAfterChange event for the textbox.&lt;br /&gt;Steps involved&lt;br /&gt;1)Set the default value for the field as 0.&lt;br /&gt;&lt;br /&gt;2)Then write the following code in the OnAfterChange Event&lt;br /&gt;&lt;br /&gt;string checklist="abcdefghijklmnopqrstuvwxyz`~!@#$%^&amp;*()-_+={}[]|";&lt;br /&gt;			char [] alphabet=checklist.ToCharArray(0,46);&lt;br /&gt;			string strNumber=e.Site.text;&lt;br /&gt;			for(int i=0;i&amp;lt;strNumber.Length;i++)&lt;br /&gt;			{&lt;br /&gt;				for(int j=0;j&amp;lt;alphabet.Length;j++)&lt;br /&gt;				{&lt;br /&gt;					if(strNumber&lt;i&gt;==alphabet[j])&lt;br /&gt;					{&lt;br /&gt;						thisXDocument.UI.Alert("Enter a valid Number");&lt;br /&gt;						e.Site.text="0";&lt;br /&gt;						return;&lt;br /&gt;					}&lt;br /&gt;				}&lt;br /&gt;			}&lt;br /&gt;</description></item><item><title>Re: Numeric only fields</title><link>https://www.infopathdev.com:443/forums/thread/9035.aspx</link><pubDate>Fri, 10 Feb 2006 03:43:24 GMT</pubDate><guid isPermaLink="false">033a2e2d-04e2-4a9d-be01-a4634161eefd:9035</guid><dc:creator>K.Ramana Reddy</dc:creator><slash:comments>0</slash:comments><comments>https://www.infopathdev.com:443/forums/thread/9035.aspx</comments><wfw:commentRss>https://www.infopathdev.com:443/forums/commentrss.aspx?SectionID=41&amp;PostID=9035</wfw:commentRss><description>Hi,&lt;br /&gt;Using screen Tip or placeholder we can direct user to only enter numeric values.&lt;br /&gt;After  selecting  data Type as whole number for a text box, if we enter characters, it will display red dashed bar  in that textbox,&lt;br /&gt;I think this is fine to tell user to enter only numeric values,&lt;br /&gt;&lt;br /&gt;Thanks.&lt;br /&gt;&lt;br /&gt;K.Ramana Reddy&lt;br /&gt;Infopath Dev India</description></item><item><title>Numeric only fields</title><link>https://www.infopathdev.com:443/forums/thread/5345.aspx</link><pubDate>Fri, 10 Feb 2006 00:31:36 GMT</pubDate><guid isPermaLink="false">033a2e2d-04e2-4a9d-be01-a4634161eefd:5345</guid><dc:creator>vista_live</dc:creator><slash:comments>0</slash:comments><comments>https://www.infopathdev.com:443/forums/thread/5345.aspx</comments><wfw:commentRss>https://www.infopathdev.com:443/forums/commentrss.aspx?SectionID=41&amp;PostID=5345</wfw:commentRss><description>Hi,&lt;br /&gt;Is it possible to restrict user to enter numeric values only in a textbox. There is an option for data type, but it will let you enter alpaha characters and then warns you when you try to submit the form.&lt;br /&gt;(Handling keydown/up events??)&lt;br /&gt;Thanks in advance guys &lt;br /&gt;:)</description></item></channel></rss>