Home All Groups Group Topic Archive Search About

sending email when running on diff machine

Author
7 Mar 2006 8:34 PM
Dennis Benjamin
Hi All

Hope this isn't a FAQ - I've looked for several hours and can't find an
answer. I've written my first VB.NET app, a ~20 line console application
that opens up an Excel document, compares the number of the last line to the
number stored in a text document, and if they're different sends an email
..It's just a tool to alert me when someone has added a request to our log. I
wrote it as a standalone app because of the ungodly mess required to allow
me to put a macro inside an Excel sheet and not have to instruct all our
users to ignore the security warning - it requires digital signing and a
keyserver and someone who understands all that.
So, my little app runs great, emails me if it ffinds a difference, but my
machine is a notebook that goes home w/ me. So I want to run this on a
desktop machine here at work. And when I try that, I get the following error
message:

Unhandled Exception: System.Web.HttpException: Could not access
'CDO.Message' ob
ject. ---> System.Reflection.TargetInvocationException: Exception has been
throw
n by the target of an invocation. --->
System.Runtime.InteropServices.COMExcepti
on (0x80040220): The "SendUsing" configuration value is invalid.

   --- End of inner exception stack trace ---

From googling around there seem to be many ways to get this error, but none
that I've found are unique to running on a machine different from the one
where the code is compiled. Any suggestions? Do I have to install something
on the target machine?

Thanks for any help!
Dennis

Author
22 Mar 2006 2:17 AM
Kim Greenlee
I'm going to take a WAG...have you looked at permissions?  Automated Excel
requires a valid login profile and the proper COM security settings.  In this
blog post
http://krgreenlee.blogspot.com/2006/03/digipede-distributing-excel_10.html in
a section under Administration Issues: User Identity I walk you through how
to make sure the COM security settings for Excel will allow automated Excel.

Good luck,

Kim

--
digipede - Many legs make light work.
Grid computing for the real world.
http://www.digipede.net
http://krgreenlee.blogspot.net


Show quoteHide quote
"Dennis Benjamin" wrote:

> Hi All
>
> Hope this isn't a FAQ - I've looked for several hours and can't find an
> answer. I've written my first VB.NET app, a ~20 line console application
> that opens up an Excel document, compares the number of the last line to the
> number stored in a text document, and if they're different sends an email
> ..It's just a tool to alert me when someone has added a request to our log. I
> wrote it as a standalone app because of the ungodly mess required to allow
> me to put a macro inside an Excel sheet and not have to instruct all our
> users to ignore the security warning - it requires digital signing and a
> keyserver and someone who understands all that.
> So, my little app runs great, emails me if it ffinds a difference, but my
> machine is a notebook that goes home w/ me. So I want to run this on a
> desktop machine here at work. And when I try that, I get the following error
> message:
>
> Unhandled Exception: System.Web.HttpException: Could not access
> 'CDO.Message' ob
> ject. ---> System.Reflection.TargetInvocationException: Exception has been
> throw
> n by the target of an invocation. --->
> System.Runtime.InteropServices.COMExcepti
> on (0x80040220): The "SendUsing" configuration value is invalid.
>
>    --- End of inner exception stack trace ---
>
> From googling around there seem to be many ways to get this error, but none
> that I've found are unique to running on a machine different from the one
> where the code is compiled. Any suggestions? Do I have to install something
> on the target machine?
>
> Thanks for any help!
> Dennis
>
>
>