Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Chris Miller on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Email SMTP Novell Groupwise

Status
Not open for further replies.

T111

Programmer
Jun 28, 2003
91
IE
Hi,

I got a program working to send mail through exchange servers on a windows 2000 server - However when I went to the customer site they use Novell 6.5 and GroupWise 6.5 and they have an SMTP server but the program crashes out.

Help appreciated,
T111.
 
I would advise you to read faq222-2244.

Please post the code you have, and any error messages you are getting. Debug the program if you have to.

If your program is NOT using SMTP to send email, then you have do make it do it. Its easy, and there is at least 1 free SMTP program available for VB6 that you can incorporate easily with any VB program.

Regards

Frederico Fonseca
SysSoft Integrated Ltd
 
When you post error messages, please also post the line that is causing them!!
 
I am sorry guys it turns out my code was fine all along, they had security issues socket closed. As the code just ended I was unable to pinpoint the error. I only found this out when sending through BMail. Thanks for your help. Below is the steps from VB (SMTP), Bmail (creates a batch file and runs) and groupwise automation for anyone who needs it.

Standard VB
Dim iMsg
Dim iConf
Dim Flds

Const cdoSendUsingPort = 2
Set iMsg = CreateObject("CDO.Message")
Set iConf = CreateObject("CDO.Configuration")
Set Flds = iConf.Fields

With Flds
.Item(" = cdoSendUsingPort
.Item(" = SMTPServerName
.Item(" = 10
.Update
End With

With iMsg
Set .Configuration = iConf
.To = GetEmailAddress(rstMailDetails.Fields(0))
.From = EmailSentFrom
.Subject = EmailSubject
.HTMLBody = EmailBody
.Send
End With

Set iMsg = Nothing
Set iConf = Nothing
Set Flds = Nothing

Alternatively BMail (free exe program – bmail.exe, creates a batch file and runs)

Private Sub SendBMail(LocOfBMail, ToEmail, FromEmail, smtpserver, EmailSub, EmailBody, PortNo)
On Error GoTo Error_Handler

Dim RunExe, StringToShell

StringToShell = LocOfBMail & "bmail -h -t " & ToEmail & " -f " & FromEmail & " -s " & smtpserver & " -a " & EmailSub & " -b " & EmailBody & " -p " & PortNo

Dim TempFile As String
TempFile = CurrentProject.Path & "\a.bat"
Dim iFileNo As Integer
iFileNo = FreeFile
Open TempFile For Output As #iFileNo


Print #iFileNo, StringToShell
Close #iFileNo
RunExe = Shell(TempFile, vbHide)

Exit Sub
Error_Handler:
MsgBox "error occured when sending the BMail! -" & Err.Number & vbCrLf & Err.Description
End Sub

Or Else groupwise automation (download free program - gwsend.exe)

Private Sub SendGWMail(GWEXELoc, EmailAdd)
On Error GoTo EH

Dim wshell
wshell = Shell(GWEXELoc & " /t=" & EmailAdd & " /s=""Email Subject"" /m=""Email body""", vbHide)
Set wshell = Nothing

Exit Sub
EH:
MsgBox "Error occured number : - " & Err.Number & vbCrLf & Err.Description
End Sub
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top