This explains how to get around the outlook security popup if you have admin rights to the exchange server.
http://www.microsoft.com/office/ork/...ndx/appa11.htm
Hope this helps.
LJ
Printable View
This explains how to get around the outlook security popup if you have admin rights to the exchange server.
http://www.microsoft.com/office/ork/...ndx/appa11.htm
Hope this helps.
LJ
Hi,Quote:
Originally posted by lsmeteor
This is a security patch that was introduced a while back with Win 2000 SP2 or Outlook 2000 SP2 or something like that. Couldn't find a way to get around it for now unless not using Outlook to send email.
Infact, the code given to send an e-mail from a VB program really works great.
Wonderful!!!!!!!!!!
But, I want to know if there is an alternate way of doing it, I mean without the Outlook in picture.
Thanks & Regards,
Lavanya
You can use the winsock and talk to the email server via SMTP. A sample code has already provided in the previous posts, take a look at Cimperiali's 5 ways to send email thru VB.
Quote:
Originally Posted by phinds
This works OK- but it sends mail the before the user can enter text into the body. I'd like to bring up Outlook, start an empty Email , fill in the TO: address, subject, and maybe a line of two in the Body, then allow the user to fill in the rest of the body of the message, then send it, after they finish typing it.
I've looked in the FAQ and the Five Ways to send email- they are variations on yoru method. I can't get the command line completion to work on the objOutlook object, so I cant see the other methods.
i managed to send out an email successfullyQuote:
Originally Posted by Cimperiali
but would like to find out is it possible to do formatting for the body of the email which sends out by outlook? meaning something lk
We received your response.
Please note that your reference number is <number>.
Please furthur correspond with us using this reference number.
Thank You.
Company Name.
the reference number part is not a prob, but the line breaks are the headache ..
Hi,
Why dont u Use a String Variable and set it to like that :
lBody = "We received your response." & chr(13) & "Please note that your reference number is " & Num & chr(13) & "Please furthur correspond with us using this reference number." & chr(13) & chr(13) & "Thank You."
and then pass it to the Body part
.Subject = "Hello World (one more time)..."
.Body = lBody
I hope it should Work for you !
I think that the easiest method whould be something likeQuote:
Originally Posted by Toracle
Hope this helps....Code:Public MSG_Str as string
MSG_Str = "We received your response." & chr(10) & chr(13) & "Please note that your reference number is" .........
With objOutlookMsg
.To = "[email protected]
.Cc = "[email protected]"
.Subject = "Hello World (one more time)..."
.Body = MSG_Str
.Attachments.Add ("c:\myFileToSend.txt")
.Send 'Let´s go!
End With
Gremmy
it works! thanks!Quote:
Originally Posted by GremlinSA
one last question. if i were to add a company name at the end like say "Toracle Pte Ltd" and would like it to be bold. How do i make it bold?
Hi,Quote:
Originally Posted by Cimperiali
I have tried 3rd way (using winsock control)
but getting run time error with no 424.
Can you plz suggest
if you want formatting for your email, i think you have to use the winsock version and try to implement the MIME. Using "text/html" mime you can tke advantage of the HTML formatting.Quote:
Originally Posted by Toracle
at what part of the code?Quote:
Originally Posted by omshivaprasad
Have a look atQuote:
Originally Posted by lsmeteor
http://www.contextmagic.com/express-clickyes/
This solved the problem for me.
Error is in the line SendEmail ....
in command1 button.
I have created two buttons,
one control of winsock
all the code is copied..
Private Sub Command1_Click()
SendEmail txtEmailServer.Text, txtFromName.Text, txtFromEmailAddress.Text, txtToEmailAddress.Text, txtToEmailAddress.Text, txtEmailSubject.Text, txtEmailBodyOfMessage.Text
Please suggest modifications
hi
i used that code and it does open outlook. but the problem is that it does not send the mail. it says verify e-mail address in the account settings.
pls help me.
thanx in advance
Ajay.N.Moorthy
It is very simple!!!!!!!!!!!!!!!!!!!
Imports System.Net.Mail
Imports System.Net.AuthenticationSchemes
Imports System.Net
Private Sub Button2_Click(sender As System.Object, e As System.EventArgs) Handles Send.Click
SendTo = TextBox2.Text
Message = TextBox3.Text
subject = TextBox1.Text
Dim myclient2 As New SmtpClient("p99-smtp.mail.me.com")
Dim nc2 As New NetworkCredential((email here, password")
myclient2.Credentials = nc2.GetCredential("p99-smtp.mail.me.com", 993, "Auto")
Dim mailme As New MailMessage(email, SendTo, subject, Message)
myclient2.SendAsync(mailme, mailme)
End Sub
HOPE IT HELPS!!!!!!!!!!!!!!!