clicking on a field to send mail

  • Thread starter Thread starter Jean-Paul
  • Start date Start date
J

Jean-Paul

In my table my email-adresses are stored like (e-mail address removed)

I stored it as a txt field...
Now I changed the fields property into "hyperlink"

When I navigate through the different records, the field-content is now
underlined and blue (which is correct)

Now I wrote:

Private Sub mailadres_Click()

SUBJECTBOX = "Mailing 4-parts"
MESSAGEBOX = ""
DoCmd.SendObject , , , "MAILTO:" & Me!mailadres, , , [SUBJECTBOX],
[MESSAGEBOX], -1
End Sub

My mail program opens and in the TO-screen I get:

MAILTO:[email protected]#http://[email protected]#

Which of course isn't correct...

What did I do wrong?
 
Jean-Paul

The 'hyperlink' field type contains all those extra pieces (separated by
"#"s). Convert it back to "text" to start with.

Then add code to your control's "Click" event that sends (email) to the text
string in the control/field.

Regards

Jeff Boyce
Microsoft Office/Access MVP
 
Back
Top