﻿<?xml version="1.0" encoding="UTF-8"?><rss version="2.0" xmlns:dc="http://purl.org/dc/elements/1.1/"><channel><title>StrataFrame Forum » StrataFrame Application Framework - V1 » Issues  » Limit input into a bound Textbox</title><generator>InstantForum 2017-1 Final</generator><description>StrataFrame Forum</description><link>http://forum.strataframe.net/</link><webMaster>StrataFrame Forum</webMaster><lastBuildDate>Tue, 09 Jun 2026 02:35:15 GMT</lastBuildDate><ttl>20</ttl><item><title>Limit input into a bound Textbox</title><link>http://forum.strataframe.net/FindPost25229.aspx</link><description>The following is the definition of the field in the database:   [Event] [char](2) NOT NULL, and the following is what I have as the default in the database:  DEFAULT ('') FOR [Event].&lt;br&gt;
&lt;br&gt;
How do I limit the user from entering only CC in the bound text box on a form or leaving it blank?  If the user enters anything else I want to set it back to '' and return to the input form.&lt;br&gt;
&lt;br&gt;
I have tried using the CheckRulesonCurrentRow like the following but it does not seem to work:&lt;br&gt;
&lt;br&gt;
if me.sportbo.event &lt;&gt; "CC" and me.sportbo.event &lt;&gt; "" THEN&lt;br&gt;
return False&lt;br&gt;
endif &lt;br&gt;
&lt;br&gt;
I have also tried me.sportbo.event &lt;&gt; " " AND me.sportbo.event &lt;&gt; "  " (one space and two spaces between the "").&lt;br&gt;
I also tried me.sportbo.event &lt;&gt; string.empty&lt;br&gt;
&lt;br&gt;
It should be easy I think.  TIA&lt;br&gt;
&lt;br&gt;
&lt;br&gt;
&lt;br&gt;</description><pubDate>Tue, 17 Nov 2009 20:08:27 GMT</pubDate><dc:creator>Terry Bottorff</dc:creator></item><item><title>RE: Limit input into a bound Textbox</title><link>http://forum.strataframe.net/FindPost25235.aspx</link><description>Alright I'll think about that. Thanks.</description><pubDate>Tue, 17 Nov 2009 20:08:27 GMT</pubDate><dc:creator>Terry Bottorff</dc:creator></item><item><title>RE: Limit input into a bound Textbox</title><link>http://forum.strataframe.net/FindPost25233.aspx</link><description>Also if you don't mind using an Integer field instead of Character, you can create a Public Enum with the values allowed and bind the combobox to that Enum and that will take of the problem. I do that all the time for very short lookup options.</description><pubDate>Tue, 17 Nov 2009 18:26:19 GMT</pubDate><dc:creator>Edhy Rijo</dc:creator></item><item><title>RE: Limit input into a bound Textbox</title><link>http://forum.strataframe.net/FindPost25232.aspx</link><description>Makes sense thank you.</description><pubDate>Tue, 17 Nov 2009 16:36:42 GMT</pubDate><dc:creator>Terry Bottorff</dc:creator></item><item><title>RE: Limit input into a bound Textbox</title><link>http://forum.strataframe.net/FindPost25231.aspx</link><description>[quote][b]Terry Bottorff (11/17/2009)[/b][hr]How do I limit the user from entering only CC in the bound text box on a form or leaving it blank?  If the user enters anything else I want to set it back to '' and return to the input form.[/quote]&lt;br&gt;
Hi Terry,&lt;br&gt;
&lt;br&gt;
There are many ways to do this, but if they can only enter some specific data, then use a ComboBox and either preset the values or use a lookup table.</description><pubDate>Tue, 17 Nov 2009 15:49:34 GMT</pubDate><dc:creator>Edhy Rijo</dc:creator></item></channel></rss>