Jim,
Typically you shouldn't need to authenticate to your exchange server before
sending an email. But that would all depend on how your network is set up.
Try this code and see if it works. You'll get a permissions error if you
need to authenticate...
Dim Message As New System.Web.Mail.MailMessage
Message.BodyFormat = Mai.MailFormat.Text '---Can also be set to HTML
Message.To = "[your email address to send to]"
Message.From = "[your from email address here]"
Message.Subject = "Help Desk Alert!"
Message.Body = "Main message"
Dim Mail As System.Web.Mail.SmtpMail
Mail.SmtpServer = "localhost" '---If your web server is set up to send email
via your exchange server (a common setup) specifying local host will work.
Otherwise try naming your exchange server here.
Mail.Send(Message)
--
Sincerely,
S. Justin Gengo, MCP
Web Developer / Programmer
www.aboutfortunate.com
"Out of chaos comes order."
Nietzsche
"Jim in Arizona" <tiltowait@hotmail.com> wrote in message
news:uBk0CTwsFHA.2880@TK2MSFTNGP12.phx.gbl...[color=blue]
> I've made an application that is a computer problems (tickets) system. The
> employee goes to a web page and posts the comptuer problem they're having.
> Then, the IS staff goes to another webpage (both pages aspx of couse)
> which shows the posts by the employees. From there, we assign the problems
> (tickets) to each other, set priorities and add notes as neccessary.
>
> What I want to do is, when an employee posts a new problem, have an email
> sent out to our email address so we know when a new problem has been
> posted. I thought about doing it with SQLMail but i've had all kinds of
> problems making that work and I've given up on it. There's a bit more to
> learn with that since I've never created any kind of trigger or strored
> procedure before.
>
> We have a win2000 AD setup and use exchange2000 as our email server. I was
> thinking of some kind of code that will execute when they click the button
> that does the DB insert statement. I absolutely hope that, if anyone does
> have an example, that it is in VB. :)
>
> Also, since exchange authentication is done via AD, how would I go about
> setting up something like that on the server(s) side? Since anonymous
> access is turned off on my IIS 5.0 server, how would this work, or would
> that even matter?
>
> TIA!
> Jim
>[/color]