Home | Contact Us | FAQ | Search & Site Map | Link to Us
Sign In | Join | Other 45 Sites in Network
Home
DiscussionsAccessExcelInfoPathOutlookPowerPointPublisherWord
DirectoryUser Groups
Related Topics
Outlook ExpressInternet ExplorerWindowsMS Server ProductsMore Topics ...

MS Office Forum / Word / Programming / May 2008

Tip: Looking for answers? Try searching our database.

Forms with text boxes

Thread view: 
Enable EMail Alerts  Start New Thread
Thread rating: 
toomsk - 17 May 2008 18:03 GMT
I would like to make a form in Word 2003 (I could use Publisher or Excel)
where I can have text boxes that I could limit the characters allowed in that
text box. Also if possible, in some text boxes I would like to keep a running
total of how many characters are left to be used in that text box.

Is this possible???

I'm not a programer..only a novice user...I would need detailed help on how
to do this.

Thanks,
toomsk
Helmut Weber - 17 May 2008 18:24 GMT
Hi toomsk,

something along these lines:

Private Sub TextBox1_Change()
Dim Total As Long
Total = 50
If Len(TextBox1.Text) > 40 Then
  MsgBox "characters left: " & Total - Len(TextBox1.Text)
  TextBox1.Text = Left(TextBox1.Text, 50)
End If
End Sub

--

Greetings from Bavaria, Germany

Helmut Weber, MVP WordVBA

Vista Small Business, Office XP
 
Sign In
Join
My Latest Posts
My Monitored Threads
My Blog
My Photo Gallery
My Profile
My Homepage

Start New Thread
Enable EMail Alerts
Rate this Thread



©2008 Advenet LLC   Privacy Policy - Terms of Use
This website includes both content owned or controlled by Advenet as well as content owned or controlled by third parties.