Jump to content

emc65

Member
  • Posts

    2
  • Joined

  • Last visited

  • Donations

    0.00 USD 
  • Country

    United States

About emc65

emc65's Achievements

0

Reputation

  1. I am getting an error when running my VB script. The error states: Line: 7 Char: 1 Error: Type mismatch: 'temp' I have this vb script running on box but not another. The OS is WindowsServer 2003. Here is the vb code: ============================= Dim shell strComputerName="ETLT1" set shell = createobject("wscript.shell") set exec = shell.exec("cmd /c net start | find /C ""Inform""") temp = exec.stdout.readline 'msgbox temp if temp <> 2 then Dim iMsg Set iMsg = CreateObject("CDO.Message") Dim iConf Set iConf = CreateObject("CDO.Configuration") Dim Flds Set Flds = iConf.Fields Const cdoSendUsingMethod = "http://schemas.microsoft.com/cdo/configuration/sendusing" Const cdoSendUsingPort = "25" Const cdoSMTPServer = "http://schemas.microsoft.com/cdo/configuration/smtpserver" Const cdoSMTPServerPort = "http://schemas.microsoft.com/cdo/configuration/smtpserverport" Const cdoSMTPConnectionTimeout = "http://schemas.microsoft.com/cdo/configuration/smtpconnectiontimeout" Const cdoSMTPAuthenticate = "http://schemas.microsoft.com/cdo/configuration/smtpauthenticate" Const cdoBasic = "1" Const cdoSendUserName = "http://schemas.microsoft.com/cdo/configuration/sendusername" Const cdoSendPassword = "http://schemas.microsoft.com/cdo/configuration/sendpassword" With Flds ' assume constants are defined within script file .Item(cdoSendUsingMethod) = 2 ' cdoSendUsingPort .Item(cdoSMTPServer) = "NCHWT" .Item(cdoSMTPConnectionTimeout) = 100 ' quick timeout .Item(cdoSMTPAuthenticate) = cdoBasics .Item(cdoSendUserName) = "Inform" .Item(cdoSendPassword) = "PtPPPM" '.Item(cdoURLProxyServer) = "server:80" '.Item(cdoURLProxyBypass) = "<local>" '.Item(cdoURLGetLatestVersion) = True .Update End With With iMsg Set .Configuration = iConf .To = "developers@abc.com" .From = "developers@abc.com" .Subject = "Action Required - " & strComputerName & " Informatica Service is not running" '.CreateMHTMLBody "http://example.com" .TextBody = "Informatica Service is not running on " & strComputerName & "..." '.AddAttachment "C:\files\mybook.doc" .Send End With End If
  2. I set up a System Environment Variable on a Windows Server 2003. I want Tivoli Scheduler to run a bat file on this Windows Server. The bat file contains the System Environment Variable login and password but the Tivoli Scheduler does not recognize the System Environment Variable. How can I ge Tivoli Scheduler to run this bat file while securing the credentials (login/password)? Thanks.
×
×
  • Create New...