?
Solved

Create a TextArea control in MS Access form

Posted on 2006-12-02
6
Medium Priority
?
2,218 Views
Last Modified: 2012-06-21
hi guys,

i do not find any option to add a textarea control into my ms accessform, only textbox. Can someone teach me how to do it. thank you.

0
Comment
Question by:prinx
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
6 Comments
 
LVL 16

Expert Comment

by:Rick_Rickards
ID: 18059224
What you're looking for sounds like the "Text Box" Control.

There is a toolbar that is on by default that should give you access to this control when your form is in Design View. The Button looks like...

AB|

Click on that button and drop the text box anyplace on the form you'd like.  You can even give it different dimentions by going into the properties menu (which you can get to by right clicking on the text box and slelcting properies), or by clicking on onne of it's 8 anchor points whereby you can resize by a click, drag and release wth the moust..

If you have the form opened in design veiw all the above should apply.  Just remember to have the form in Design View as that is what allows you to build your form (and add text boxes for example).


Rick
0
 
LVL 44

Accepted Solution

by:
Arthur_Wood earned 200 total points
ID: 18059638
TextArea is a Control on a Web Page, that allows multiple lines of text (a standard Web Form TextBox is a single line only).  On an Access Windows form, the TextBox contol is 'multi-line' automatically, but to use the capability, when entering text, to get the second or third or... line, you use the Control Key + the Enter key (press BOTH at the same time).  That will move the cursor to the start of the next line, then you can type as usual.  You can have as many line in a TextBox as you need, justr end each line with Control+Enter

AW
0
 
LVL 34

Expert Comment

by:jefftwilley
ID: 18059741
If you're adding this control as described above, and it is bound to a table source, make sure that table source is defined as a memo field. Text fields are limited to only 255 characters.
J
0
Prepare for your VMware VCP6-DCV exam.

Josh Coen and Jason Langer have prepared the latest edition of VCP study guide. Both authors have been working in the IT field for more than a decade, and both hold VMware certifications. This 163-page guide covers all 10 of the exam blueprint sections.

 

Author Comment

by:prinx
ID: 18060153
Thanks guys...anyway, is there no other way to make it works more like a textarea in a webpage, without using ctrl-enter? thanks
0
 
LVL 34

Expert Comment

by:jefftwilley
ID: 18060358
This seems to work

Private Sub yourfield_KeyDown(KeyCode As Integer, Shift As Integer)
Dim myString As String
Dim strLen As Long
myString = Me.yourfield.Value
strLen = Len(myString)
Select Case KeyCode
  Case vbKeyReturn
    myString = myString & " " & Chr(10) & ""
    Me.yourfield.Value = myString
    Me.yourfield.SelStart = strLen + 2
    KeyCode = 0
End Select
End Sub
0
 
LVL 34

Expert Comment

by:jefftwilley
ID: 18060617
revised after market...

Just to demonstrate...not recommended
just cause you can do a thing...doesn't mean you should

Option Compare Database

Dim FullString As String

Private Sub yourfield_GotFocus()
FullString = ""
End Sub

Private Sub yourfield_KeyDown(KeyCode As Integer, Shift As Integer)
StringCount = StringCount + 1
If KeyCode <> vbKeyReturn Then
    FullString = FullString & Right(Me.yourfield.Text, 1)
Else
    FullString = FullString & Right(Me.yourfield.Text, 1) & Chr(10) & " "
    Me.yourfield.Value = FullString
    Me.yourfield.SelStart = Len(FullString)
    KeyCode = 0
End If
End Sub
0

Featured Post

Windows Server 2016: All you need to know

Learn about Hyper-V features that increase functionality and usability of Microsoft Windows Server 2016. Also, throughout this eBook, you’ll find some basic PowerShell examples that will help you leverage the scripts in your environments!

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Access custom database properties are useful for storing miscellaneous bits of information in a format that persists through database closing and reopening.  This article shows how to create and use them.
The Windows Phone Theme Colours is a tight, powerful, and well balanced palette. This tiny Access application makes it a snap to select and pick a value. And it doubles as an intro to implementing WithEvents, one of Access' hidden gems.
Get people started with the utilization of class modules. Class modules can be a powerful tool in Microsoft Access. They allow you to create self-contained objects that encapsulate functionality. They can easily hide the complexity of a process from…
In Microsoft Access, learn different ways of passing a string value within a string argument. Also learn what a “Type Mis-match” error is about.
Suggested Courses

770 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question