PDA

View Full Version : sending email from excel through outlook



elsuji
12-23-2019, 10:53 AM
Dear Team,

I need code for sending email from excel through outlook.

My condition is,

I am having outstanding data's in Sheet1 ( Customer Name, Inv No, Date, Outstanding Amt, Location , Equip, Product, M/c. Sl. No, Service Engg, No. of Days Pending)

Service Engg name and email ID details in Sheet2

When i am press the Send Email button, first it should ask to select the Service Engg name.


Once I select any Service Engg name, that particular engineer name should auto filter and copy all data's with heading(Customer Name, Inv No, Date, Outstanding Amt, Location , Equip, Product, M/c. Sl. No, Service Engg, No. of Days Pending) which is more than 30 days and send by email.


Email Title: Service Payment outstanding details
Email Subject : Dear Engineer,
Pls find the updated service payment outstanding details for your reference. Kindly contact with customer and try to cleat the payment as soon as possible.
And paste the data's here

I am attached my excel here for your reference.

Kindly do the needful.

elsuji
12-26-2019, 03:08 AM
Has anyone please send reply for my query

gmayor
12-28-2019, 01:42 AM
It is the Christmas holiday period. Only odd compulsive characters like me tend to access the forums at this time :banghead:

The attached should be close to what you want, though I don't understand your outstanding time scales - you can modify it to give the results you require.

elsuji
12-28-2019, 08:01 AM
Dear Gmayor,

Thanks for your reply. The attached file is working great.

But one clarification.
25707

I change the code with adding tabs for proper alignment of data. But improper alignment of data is displaying on mail body (Please refer the attached image).

Is it possible to attached this data like table format with borders.

gmayor
12-29-2019, 06:41 AM
It is a little more complicated to use a table, but see attached. The code is annotated should you wish to add more columns.

elsuji
01-12-2020, 10:42 AM
Dear Graham Mayor,

First of all sorry for late replying your message.

Above your attachment is working great. Thanks for your support.

I need one more support from you.

I had posted one query on http://www.vbaexpress.com/forum/showthread.php?66578-Send-service-reminder-mail-based-an-hour-reading But i did not get any reply from the forum.

Can you please support me for my query which is posted on the above link