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 Mike Lewis on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Passing contents of a textbox to a function

Status
Not open for further replies.

shteev

Programmer
Jul 15, 2003
42
0
0
Hi, I have a form in Microsoft Access. There is a textbox which contains a filename, and a button which calls a VB function. i want to pass the string in the textbox to the VB function as an argument. How do I do this?
 
The button has the following event:

On Click = ProcessTextFile(arg1)

The function ProcessTextFile() is passed a single argument when it's called. I want to pass whatever the contents of a particular text box are (let's call it TextBox1).

 
You should be able to use the name of the control:

= ProcessTextFile([TextBox1])
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top