>>lcOnError = On("ERROR") >>ON ERROR do procIgnoreError >> >>This.omailer.Connect (Thisform.phostname) && connect to Exchange Server >> >>If This.omailer.lastError > 0 && Error in connecting to Exchange Server >> lcError = [Mabry MailX Error # ]+Alltrim(Str This.omailer.lastError,8.0))+[ in frmSwitchDist.Init] >> * log the error to a text file >> DO procLogError WITH lcError >> * advise the user of the problem >> lcMsgText = "Unable to Connect to Exchange Server - please contact Network support !" >> lcMsgText = lcMsgText + CHR(13)+CHR(10) >> lcMsgText = lcMsgText + "This screen will now close ..." >> =Messagebox(lcMsgText,16,"Exchange Server Connection Error") >> On Error &lcOnError >> thisform.Release() >>ENDIF >> >>