HP3000-L Archives

September 2001, Week 1

HP3000-L@RAVEN.UTC.EDU

Options: Use Monospaced Font
Show Text Part by Default
Show All Mail Headers

Message: [<< First] [< Prev] [Next >] [Last >>]
Topic: [<< First] [< Prev] [Next >] [Last >>]
Author: [<< First] [< Prev] [Next >] [Last >>]

Print Reply
Subject:
From:
John Dass <[log in to unmask]>
Reply To:
John Dass <[log in to unmask]>
Date:
Thu, 6 Sep 2001 05:41:14 -0400
Content-Type:
text/plain
Parts/Attachments:
text/plain (38 lines)
Hello, I need some help with Reflection Basic programming. I am
trying to monitor the existence of a file and once the file is
deleted, a message box pops-up to tell me that the file is deleted.
Below is the way I code it, but somehow I am unable to read the
results of my LISTF command to determine if the file is existent
or not.

Please help me.

Sub Main

   file_exist = true
   fname = Application.InputBox("Filename to mont","DSCOPY from PEACE.SHR @
CESIUM")
   if fname <> "" then
      while file_exist
         application.transmit "listf " & fname & CR
         msgbox("wait for host trigger")
         application.waitforhosttrigger
         msgbox("wait 1 sec")
         application.wait 1
         msgbox("read one line")
         result = application.readline(1)
         msgbox("after read")
         ' result returns BLANK !!! why???
         msgbox(result)
         if instr(result,"CIERR") > 0 then
            msgbox("heehee")
            file_exist = false
         end if
      wend
   end if

End Sub

* To join/leave the list, search archives, change list settings, *
* etc., please visit http://raven.utc.edu/archives/hp3000-l.html *

ATOM RSS1 RSS2