473,797 Members | 3,199 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

how can i make unbound box limit to one line

Dear Access Programmers,

I can't seem to figure this out.

The text boxes that are used to input data via my form are
unbound, I want to restrict the user to only put input that
is one line.

Eg.

Input your surname., you shouldn't be able to press the
enter/return key after since it will take the user to the next
line and the infomation will dissapear in the form box since
its a new line, thus you would have to backup to get the
data back.

How can I limit the data entre to one liners ? is there a simply
way ?

******
Seconly, how come I can't seem to get my toolbox, field list
to show ? I enter the forms and press the design view, but
can't seem to have any other views ? Is there a special key
I can press or what?
Nov 12 '05 #1
2 1726
There should be buttons on the Design View toolbar that will open up the
Toolbox and Properties sheet.

To prevent the Enter key, in the KeyDown event

If KeyCode = 13 Then KeyCode = 0

--
Wayne Morgan
Microsoft Access MVP
"Earthling" <in******@earth planet09087.com > wrote in message
news:k9******** **********@twis ter01.bloor.is. net.cable.roger s.com...
Dear Access Programmers,

I can't seem to figure this out.

The text boxes that are used to input data via my form are
unbound, I want to restrict the user to only put input that
is one line.

Eg.

Input your surname., you shouldn't be able to press the
enter/return key after since it will take the user to the next
line and the infomation will dissapear in the form box since
its a new line, thus you would have to backup to get the
data back.

How can I limit the data entre to one liners ? is there a simply
way ?

******
Seconly, how come I can't seem to get my toolbox, field list
to show ? I enter the forms and press the design view, but
can't seem to have any other views ? Is there a special key
I can press or what?

Nov 12 '05 #2
"Earthling" <in******@earth planet09087.com > wrote in message news:<k9******* ***********@twi ster01.bloor.is .net.cable.roge rs.com>...
Dear Access Programmers,

I can't seem to figure this out.

The text boxes that are used to input data via my form are
unbound, I want to restrict the user to only put input that
is one line.

Eg.

Input your surname., you shouldn't be able to press the
enter/return key after since it will take the user to the next
line and the infomation will dissapear in the form box since
its a new line, thus you would have to backup to get the
data back.
Any reason why your fields are unbound? (You like making work for
yourself?) You could set the field's length in the underlying
table... or I guess you could use the keypress event or something to
check the length of the entry and then set the keyascii value to zero
for every subsequent keypress in that field...
How can I limit the data entre to one liners ? is there a simply
way ?

******
Seconly, how come I can't seem to get my toolbox, field list
to show ? I enter the forms and press the design view, but
can't seem to have any other views ? Is there a special key
I can press or what?


Whoa, wait a minute. If your form in UNBOUND, then of course you
can't get a list of fields. Think about it - the field list is a list
of fields that are in the recordsource for the form. And that
*necessarily* means that the form is bound. Yours isn't, so you have
no fields in your field list. You want fields listed? Bind your
form.
Nov 12 '05 #3

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

11
17332
by: deko | last post by:
I need to create different recordsets based on queries that use data from unbound fields in a form. I've discovered that I can't do this, and instead need to save the data in question (usually a text string) to a table. I'm thinking the best way to do this is to use a Make Table query -- that way the table stays small -- one row -- and there is less chance for something to get overwritten. But how to create a make table query from...
3
3780
by: Dos Lil | last post by:
I have a unbound field in the subform(for calculating the datediff) which has the control property ==DateDiff("n",,). I have another unbound field in the main form which is for displaying the datediff from the subform.I have set the controls source = .Form! FRM- TimeSheet Subform is the name of the subform and TXTTtalHoursworked is the name of the unbound field in the subform.
1
3744
by: stuart | last post by:
I am trying to format a number in an unbound text field using the following format statement in the field's Exit event: txt11UnitWeight = Format(txt11UnitWeight, "00000.00") I want the number to the left of the decimal to be 5 digits long, left zero filled and 2 digits to the right of decimal. Entering a number such as 12345 will get me the required 12345.00. If I have a number such as 1234525, I want the program to format the
1
3429
by: Rob NYS | last post by:
I have a bound form for employee evaluations. This form brings in the Name, Employee Number, SSN etc. I have 8 unbound text boxes for evaluation info to be entered into. From my understanding these should not be limited to a number of characters. All the information is transferred to a word template. I do not want to store the evaluation information as it is confidential and not necessary. The form works great until the user enters more...
12
2474
by: MLH | last post by:
Can I somehow set a max length of chars entered into an unbound textbox control?
1
3522
by: Martin | last post by:
Hi, I'm having a problem with a datagridview control when trying to read the value of an unbound checkbox cell. The code below works fine if I click on any text cell, bound or unbound, and also if I click on a data bound checkbox cell. But it fails with null reference exception if I try to read the value on an unbound cell.
14
3039
by: 7stud | last post by:
Here is some example code that produces an error: class Test(object): def greet(): print "Hello" t = Test() t.greet() TypeError: greet() takes no arguments (1 given)
1
1988
by: TonyJ | last post by:
Hello! I just wonder when is it necessary to use unbound datagrid. It's far simpler to use databound datagrid by using the wizard. Can you just point on some particularly example when an unbound datagrid would be suitable. //Tony
9
2923
by: prakashwadhwani | last post by:
I have an unbound combo box in the form header. I have used an input mask "CCCC" 40 times to limit the max number of characters to 40. When I tab into the combo box & press a character say "K" for example, the entire first match gets filled in the combo box and the cursor goes to the last character of the combo box. So I can't effectively search for a "KI" until I backspace the entire entry which has got filled in. Once i remove the...
0
9685
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However, people are often confused as to whether an ONU can Work As a Router. In this blog post, we’ll explore What is ONU, What Is Router, ONU & Router’s main usage, and What is the difference between ONU and Router. Let’s take a closer look ! Part I. Meaning of...
0
9537
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can effortlessly switch the default language on Windows 10 without reinstalling. I'll walk you through it. First, let's disable language synchronization. With a Microsoft account, language settings sync across devices. To prevent any complications,...
0
10469
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers, it seems that the internal comparison operator "<=>" tries to promote arguments from unsigned to signed. This is as boiled down as I can make it. Here is my compilation command: g++-12 -std=c++20 -Wnarrowing bit_field.cpp Here is the code in...
0
10246
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven tapestry of website design and digital marketing. It's not merely about having a website; it's about crafting an immersive digital experience that captivates audiences and drives business growth. The Art of Business Website Design Your website is...
1
10209
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows Update option using the Control Panel or Settings app; it automatically checks for updates and installs any it finds, whether you like it or not. For most users, this new feature is actually very convenient. If you want to control the update process,...
0
10023
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each protocol has its own unique characteristics and advantages, but as a user who is planning to build a smart home system, I am a bit confused by the choice of these technologies. I'm particularly interested in Zigbee because I've heard it does some...
0
9066
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing, and deployment—without human intervention. Imagine an AI that can take a project description, break it down, write the code, debug it, and then launch it, all on its own.... Now, this would greatly impact the work of software developers. The idea...
0
5582
by: adsilva | last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
1
4135
by: 6302768590 | last post by:
Hai team i want code for transfer the data from one system to another through IP address by using C# our system has to for every 5mins then we have to update the data what the data is updated we have to send another system

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.