CDO .from -> using variables

Jamster45

New member
Local time
Today, 10:52
Joined
Aug 15, 2018
Messages
7
Hi There,

I have a form where i can send email from.
I want the user to fill in the senders name and the senders emailaddress.

The name is fixed but the emailaddress not, i need some help!

Here is the code

With mail
.To = Me.emailadres
.From = "" & Me.afzenderNaam & " <onzin@crap.nl>"

Someone an idea to make both fields variable?
 
Hi. You can just remove the fixed name and either ask the user to enter both together or use one more variable.
 
Well i tried that but then the fromaddress and fromname are the same then.
Any suggestion how to program it, like you said?
 
Well i tried that but then the fromaddress and fromname are the same then.
Any suggestion how to program it, like you said?
What is in Me.afzenderNaam? Is it coming from a table?
 
I have to fields in a form: FromName and FromAddress
They are not coming from a table.
 
I have to fields in a form: FromName and FromAddress
They are not coming from a table.
So, what happens if you tried:
Code:
.From = Me.FromName & " " & Me.FromAddress
 

Users who are viewing this thread

Back
Top Bottom