|
|
|
| Author |
Message |
Mighty
Joined: 05 Aug 2007 Posts: 3
|
Posted: Wed Jun 13, 2007 4:14 am Post subject: Access Exchange Client Mailbox |
|
|
Hi Guys,
I need to write a script to allow me to connect to the mailbox of a specific
exchange client. Once connected I need to be able to loop through each email
in the inbox and do the following:
1. Access the mail recipients
2. Save the details of the email (recipients, body, attachments) to an
Access DB
3. Delete the email
The save to DB part is easy but I am not sure how to do the rest - I am
presuming that it is possible. Any pointers would be appreciated.
Archived from group: microsoft>public>exchange>applications |
|
| Back to top |
|
 |
Henning Krause [MVP - Exc
Joined: 05 Aug 2007 Posts: 142
|
Posted: Thu Jun 14, 2007 1:08 am Post subject: Re: Access Exchange Client Mailbox |
|
|
Hello,
since you want to download the attachments, you should consider writing a
program instead of a script. Scripting languages like VBScript cannot handle
binary data very well.
If you are using .NET, you could use either CDO or WebDAV to access the
mailbox. CDO exposes an object mode, but requires interop. WebDAV is an HTTP
protocol extensions and can be used virtually by any programming language.
See the Exchange SDK for more information.
Best regards,
Henning Krause
"Mighty" wrote in message @microsoft.com...
> Hi Guys,
>
> I need to write a script to allow me to connect to the mailbox of a
> specific
> exchange client. Once connected I need to be able to loop through each
> email
> in the inbox and do the following:
>
> 1. Access the mail recipients
> 2. Save the details of the email (recipients, body, attachments) to an
> Access DB
> 3. Delete the email
>
> The save to DB part is easy but I am not sure how to do the rest - I am
> presuming that it is possible. Any pointers would be appreciated.
> |
|
| Back to top |
|
 |
Mighty
Joined: 05 Aug 2007 Posts: 3
|
Posted: Thu Jun 14, 2007 4:11 am Post subject: Re: Access Exchange Client Mailbox |
|
|
Hi Henning,
Firstly thanks for the response. As regards your suggestions, I need to be
able to write a script/program that I can then schedule to run automatically
every hour or so. With that in mind, is WebDAV still an option (haven't
looked into it yet)
Nick
"Henning Krause [MVP - Exchange]" wrote:
> Hello,
>
> since you want to download the attachments, you should consider writing a
> program instead of a script. Scripting languages like VBScript cannot handle
> binary data very well.
>
> If you are using .NET, you could use either CDO or WebDAV to access the
> mailbox. CDO exposes an object mode, but requires interop. WebDAV is an HTTP
> protocol extensions and can be used virtually by any programming language.
> See the Exchange SDK for more information.
>
> Best regards,
> Henning Krause
>
> "Mighty" wrote in message
> @microsoft.com...
> > Hi Guys,
> >
> > I need to write a script to allow me to connect to the mailbox of a
> > specific
> > exchange client. Once connected I need to be able to loop through each
> > email
> > in the inbox and do the following:
> >
> > 1. Access the mail recipients
> > 2. Save the details of the email (recipients, body, attachments) to an
> > Access DB
> > 3. Delete the email
> >
> > The save to DB part is easy but I am not sure how to do the rest - I am
> > presuming that it is possible. Any pointers would be appreciated.
> >
>
> |
|
| Back to top |
|
 |
Mighty
Joined: 05 Aug 2007 Posts: 3
|
Posted: Thu Jun 14, 2007 7:24 am Post subject: Re: Access Exchange Client Mailbox |
|
|
Hi Henning,
Maybe there is a better way to do what I want to do. At the moment, I have a
..Net Outlook Add-in in use which allows users to send an email and save that
email to a bespoke CRM system simultaneously. The user simply clicks my
custom send button, selects the company the email relates to and clicks send.
That will send the email but also saves it and any attachments to my CRM
database.
This is working fine - as long as the user is logged on locally and can
access the CRM database. Obviously, this won't work if the user is sending
emails from a blackberry or using OWA.
So what I was going to try to do was set up a CRM mailbox. My add-in would
just BCC my CRM mailbox and then send the email. Users sending mails from OWA
or blackberry can just manually BCC my CRM mailbox. I would then access that
mailbox periodically and save the email to the CRM database and then delete
the emails. I would have to use the recipient email addresses to decide what
company to log the email against. It's probably not an ideal solution either
but I can't think of any other way to satisfy all user types.
Can you propose a better way to do this.
"Henning Krause [MVP - Exchange]" wrote:
> Hello,
>
> since you want to download the attachments, you should consider writing a
> program instead of a script. Scripting languages like VBScript cannot handle
> binary data very well.
>
> If you are using .NET, you could use either CDO or WebDAV to access the
> mailbox. CDO exposes an object mode, but requires interop. WebDAV is an HTTP
> protocol extensions and can be used virtually by any programming language.
> See the Exchange SDK for more information.
>
> Best regards,
> Henning Krause
>
> "Mighty" wrote in message
> @microsoft.com...
> > Hi Guys,
> >
> > I need to write a script to allow me to connect to the mailbox of a
> > specific
> > exchange client. Once connected I need to be able to loop through each
> > email
> > in the inbox and do the following:
> >
> > 1. Access the mail recipients
> > 2. Save the details of the email (recipients, body, attachments) to an
> > Access DB
> > 3. Delete the email
> >
> > The save to DB part is easy but I am not sure how to do the rest - I am
> > presuming that it is possible. Any pointers would be appreciated.
> >
>
> |
|
| Back to top |
|
 |
Henning Krause [MVP - Exc
Joined: 05 Aug 2007 Posts: 142
|
Posted: Thu Jun 14, 2007 3:45 pm Post subject: Re: Access Exchange Client Mailbox |
|
|
Hello Mighty,
yes, WebDAV is a suitable for this type of task.
Best regards,
Henning Krause
"Mighty" wrote in message @microsoft.com...
> Hi Henning,
>
> Firstly thanks for the response. As regards your suggestions, I need to be
> able to write a script/program that I can then schedule to run
> automatically
> every hour or so. With that in mind, is WebDAV still an option (haven't
> looked into it yet)
>
> Nick
>
> "Henning Krause [MVP - Exchange]" wrote:
>
>> Hello,
>>
>> since you want to download the attachments, you should consider writing a
>> program instead of a script. Scripting languages like VBScript cannot
>> handle
>> binary data very well.
>>
>> If you are using .NET, you could use either CDO or WebDAV to access the
>> mailbox. CDO exposes an object mode, but requires interop. WebDAV is an
>> HTTP
>> protocol extensions and can be used virtually by any programming
>> language.
>> See the Exchange SDK for more information.
>>
>> Best regards,
>> Henning Krause
>>
>> "Mighty" wrote in message
>> @microsoft.com...
>> > Hi Guys,
>> >
>> > I need to write a script to allow me to connect to the mailbox of a
>> > specific
>> > exchange client. Once connected I need to be able to loop through each
>> > email
>> > in the inbox and do the following:
>> >
>> > 1. Access the mail recipients
>> > 2. Save the details of the email (recipients, body, attachments) to an
>> > Access DB
>> > 3. Delete the email
>> >
>> > The save to DB part is easy but I am not sure how to do the rest - I am
>> > presuming that it is possible. Any pointers would be appreciated.
>> >
>>
>>
|
|
| Back to top |
|
 |
|
|