Click here to Skip to main content
11,635,098 members (74,667 online)
Rate this: bad
good
Please Sign up or sign in to vote.
Back End : Ms Access
Front End : Vb.Net or Asp.Net or Powershell
Mailing : Outlook or server side(gmail or yahoo)

I need to retrieve the data from database and send an email to the user.

Scenario for Example:

Database looks like below,

Product_ID Product_Name Date_Of_Purchase Email_ID
p00001 Mouse 02/14/2013 thajuthemoon@gmail.com
p00002 KeyBoard 01/11/2013 thajudeentaj@gmail.com
p00003 Cleaner 01/29/2013 thajuthemoon@gmail.com
p00004 Monitor 10/10/2012 thajudeen301190@gmail.com


Output:
--------
I need like below,
View in Outlook.
Example 1:
From : thajuthemoon@gmail.com
To : thajuthemoon@gmail.com


Product ID Product Name Date of Purchase
p00001 Mouse 02/14/2013
p00003 Cleaner 01/29/2013


Example 2:

From : thajuthemoon@gmail.com
To : thajudeentaj@gmail.com


Product ID Product Name Date of Purchase
p00002 KeyBoard 01/11/2013

In one mail what are all the items the particular user purchased, it should go like above.
It should be in loop, next mail should go to the next user, next user next user.

Can anyone help me in this issue.
I am able to retrieve and send the mail by giving input.
I need it, without giving in input, it should be automated.

Please let me know if anyone know this program how to do, or any can suggest me how to do.
You can reach me @
[Email Deleted]


Regards,
Thajudeen
Posted 13-Feb-13 18:49pm
Edited 14-Feb-13 18:23pm
v2
Comments
aspnet_regiis -i at 14-Feb-13 2:28am
   
So what's the problem with this? What exact help do you need?
thajudeen301190 at 14-Feb-13 2:37am
   
I need a code, how it works.
How to send an email in loop by retrieving the data according to the email.
It should be in automated. No Manual Work.
aspnet_regiis -i at 14-Feb-13 2:29am
   
And I guess you missed to post your twitter id .. :laugh:
thajudeen301190 at 14-Feb-13 2:37am
   
:p...I dont have twitter boss.
aspnet_regiis -i at 14-Feb-13 10:08am
   
So .. Whats up.. How was the day today.. Any progress in this task ?

1 solution

Rate this: bad
good
Please Sign up or sign in to vote.

Solution 1

You can send mail from Outlook by using Exchange web Services. The below link will help you.
http://code.msdn.microsoft.com/Send-Email-with-Exchange-50189e57[^]

Examples on MSDN
http://msdn.microsoft.com/en-us/library/ms878112[^]
Hope this helps
  Permalink  
v2

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)

  Print Answers RSS
0 OriginalGriff 8,736
1 Sergey Alexandrovich Kryukov 8,419
2 Mika Wendelius 6,845
3 F-ES Sitecore 2,354
4 Suvendu Shekhar Giri 2,205


Advertise | Privacy | Mobile
Web02 | 2.8.150728.1 | Last Updated 26 Jun 2013
Copyright © CodeProject, 1999-2015
All Rights Reserved. Terms of Service
Layout: fixed | fluid

CodeProject, 503-250 Ferrand Drive Toronto Ontario, M3C 3G8 Canada +1 416-849-8900 x 100