Help on sending email (1 Viewer)

hooi

Registered User.
Local time
Today, 14:05
Joined
Jul 22, 2003
Messages
158
I'm a complete newbie when it comes to VBA, would appreciate some help here...

I have a Form bound to table 'Service' and a subform (datasheet) bound to table 'ServiceEngineer', the linked field is 'ServiceID'. The subform allows user to select the names of Engineers (email addresses of the enginners are pulled directly from Employee's table). If there are two engineers selected, I want to have a button to allow the user to click on it and it sends an email to the two selected engineers. How should I go about doing it?

I think I need something like:

Dim db As Database
Dim rsRecord As Recordset

Set db = CurrentDb()
Set rsRecord = db.OpenRecordset("ServiceEngineer",dbOpenDynaset)

That's as far as I know, I need help on the kind of search/find available for stepping through the right records in a query (containing 'ServiceEngineer' and 'Employee' table for the email addresses) so that I can send out the email.

Apprecaite any help rendered.
 
Last edited:

Hayley Baxter

Registered User.
Local time
Today, 07:05
Joined
Dec 11, 2001
Messages
1,607
Mile recently put together a sample of selecting the names from a list. I've added an email button to this example to take the items selected in the list over to outlook.

There are other ways of achieving this also, this is just one option. There are many other sample dbs posted on the forum.

Hay
 

Attachments

  • milesexample.zip
    28.3 KB · Views: 174

hooi

Registered User.
Local time
Today, 14:05
Joined
Jul 22, 2003
Messages
158
Thank you very much Hay, it's just what I need.
 
Last edited:

Users who are viewing this thread

Top Bottom