Emailing through a form in access using VBA

  • Thread starter Thread starter Fred
  • Start date Start date
F

Fred

Hello,
I am trying to email through a form using VBA and am having problems
coding in the body of the text the first and last name off the form.
Here is briefly what I want it to say.
"Parking for (Here is where I want to put (Visitors first Name,Visitors
Last Name) is confirmed. Please park in spaces 663-672 Thank You". If I
just use the text it works fine but I am not sure how to code it to
pull the names off of the form. Thank You Fred
 
This depends on how the data is displayed on your form. If the first and last
names are in seperate text boxes, it should look something like this:

"Parking for " & Me.txtNameFirst & " " & Me.txtNameLast & " is confirmed.
Please park in spaces 663-672 Thank You"

If the first and last names are in the same textbox, it will look like this:
"Parking for " & Me.txtName & " is confirmed. Please park in spaces 663-672
Thank You"

Change the txt... names to the ones in your form.

Barry
 
Thanx very much
Barry said:
This depends on how the data is displayed on your form. If the first and last
names are in seperate text boxes, it should look something like this:

"Parking for " & Me.txtNameFirst & " " & Me.txtNameLast & " is confirmed.
Please park in spaces 663-672 Thank You"

If the first and last names are in the same textbox, it will look like this:
"Parking for " & Me.txtName & " is confirmed. Please park in spaces 663-672
Thank You"

Change the txt... names to the ones in your form.

Barry
 
Back
Top