anyone know?
Printable View
anyone know?
Use winsock control. Do a search on this forum, you should be able to find plenty of examples. if you cant then just PM me, i think i have one in my code library.
Danial
Are there any other ways without using Winsock?
You could use the Outlook Object in VB to send emails through VB.
Do u know of any examples using Outlook???
Add a refeerence to the Outlook object library.
Place a button and name it cmdSend
VB Code:
Private Sub cmdSend_Click() Dim objOutlook As New Outlook.Application Dim objOutlookMsg As Outlook.MailItem ' Create new message Set objOutlookMsg = objOutlook.CreateItem(olMailItem) With objOutlookMsg .To = "[email protected]" .Subject = "Subjet here" .Body = "Hello Danial, this is just a test msg" .Importance = olImportanceHigh .Send End With Set objOutlookMsg = Nothing ' Close Outlook instance: Important! Set objOutlook = Nothing End Sub
That code seems to work, but the emails ain't arriving in my inbox
check to see if your outlook is setup properly and set it so that when ever there is a new item in the outbox it should send it. I think if u look at your outbox you will see they are probably qued up there.
BTW : what Outlook version are you using, if you are using XP then it will warn user of possible virus program trying to access their mail and will ask whether to allow access to outlook.
Yeah, they were just sitting there. What exactly do I change?
I'm using Outlook 97
Hi,
I am not sure i how set that in outlook 97, but it should be pretty similar. Go to email option and choose mail setup, there should be a check box, "Send Immediately when connected", check that and press ok. Now the email will be send as soo as you click the send button.
Hope this helps.
Danial
Nah, I'm going to have to set up Outlook Express, it doesn't have "Transport Provider". A waste of time. I'll just have to find another way of sending out an email.