Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations IamaSherpa on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Autonumbering Items in Text Box 1

Status
Not open for further replies.

infinitx

Technical User
Feb 26, 2004
212
US
Hi,

I have a button on a form that when the user clicks it, it copies the text from Case Text and Item Text (which are two separate text boxes) into one text box (ExptoWord). The user can add as many items as they want to the same Text Box (ExptoWord).

This is the code that I am using:

Code:
Me.ExptoWord = Me.ExptoWord & vbCrLf & Me.CaseText & vbCrLf & Me.ItemText

How can I Autonumber every item that the user adds to ExptoWord text box?

Thanks in advance!
 
In whatever procedure you are doing this:

Static x
if isnull(me.exptword) then x = 0
x = x+1
Me.ExptoWord = Me.ExptoWord & vbCrLf & x &":" & Me.CaseText & vbCrLf & Me.ItemText
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top