Thanks, Mark. Your first example, in particular, is a big help!

Your second example, however, has me a bit confused.

You wrote:
>>> on mouseUp
  global gFilePath
  answer file "select a file"
  if it contains ".txt" then
    put URL ("file:" & it) into AddListContents
    put it into gFilePath
  else
    answer " Not a text file"
    exit mouseUp
  end if
end mouseUp

-- work from the variable AddListContents
-- after all work is done to your var then save it using this:

on mouseUp
  global gFilePath
  put compress(AddListContents) into URL ("binfile:" & gFilePath)
  -- now your file is compressed
  -- to open and decompress it use:
  -- put decompress(URL ("binfile:" & it)) into AddListContents
  -- for none compression save:
  -- put AddListContents into URL ("file:" & gFilePath)
end mousUp

hope this helped some,

I was trying to figure out how many items are present in a given file in order to help me set the number of iterations needed to get the data out of that file and into a series of array variables.


Your second example appears, instead, to be an example of how to WRITE to a file. Or am I simply befuddled at this late hour (nearly 1 AM, my time)??

M

_______________________________________________
use-revolution mailing list
[EMAIL PROTECTED]
http://lists.runrev.com/mailman/listinfo/use-revolution

Reply via email to