Scott:
 
The problem is the colon following the Else.  VB thinks "Else:" is a label rather than an else clause of the If.
 
Pax,
Ernest 21 Oct 04
-----Original Message-----
From: White, Scott A [mailto:[EMAIL PROTECTED]
Sent: Thursday, October 21, 2004 3:55 PM
To: [EMAIL PROTECTED]
Subject: [Talk] Variable not updating

Hello,
I've got a small script that runs well except for the result of M2Result and M3Result
seen below.  The script will run and send the results to me in MOX; but it ALWAYS
sends me the  Modem.2 is in use on " & mydate and Modem.3 is in use on " & mydate
 
Oddly enough, Modem.1 sends the correct info.  Can you tell by looking at this, why it
wouldn't evaluate the If statements?  None of the devices have been in use all day; but
my script ignores that for Modem.2 and Modem.3 .  I've even initialized all three at the
beginning of the procedure.
 
 
 
Pause "Device"
Enter "MODEM.1"
    Wait 2
    If At("Device is not in use") Then
    M1Result = "Modem.1 Not In use at this time"
    Else: M1Result = "Modem.1 is in use on " & mydate
    End If
    Key "{F11}"
    Wait 1
   
   
   
        Enter "MODEM.2"
            Wait 2
            If At("Device is not in use") Then
            M2Result = "Modem.2 Not In use at this time"
            Else: M2Result = "Modem.2 is in use on " & mydate
            End If
            Key "{F11}"
            Wait 1
           
           
           
                Enter "MODEM.3"
                Wait 2
                    If At("Device is not in use") Then
                    M3Result = "Modem.3 Not In use at this time"
                    Else: M3Result = "Modem.3 is in use on " & mydate
                    End If
                    Key "{F11}"
                    Wait 1
                     
 
 
Thank you,
Scott 

 


CONFIDENTIALITY NOTICE: This e-mail communication and any attachments
may contain confidential and privileged information for the use of the
designated recipients named above.  If you are not the intended
recipient, you are hereby notified that you have received this communication in
error and that any review, disclosure, dissemination, distribution or copying
of it or its contents is prohibited. If you have received this
communication in error, please notify Saratoga Hospital immediately by e-mail at
[EMAIL PROTECTED] and destroy all copies of this communication
and any attachments.

<<attachment: image001.jpg>>

Reply via email to