Hi Robert,
What happens if you replace END with EOF?
For a "low level file" you usually need a script similar to
open file myFile for binary read
read from file myFile until EOF
close file myFile
-- it now contains the binary data
It may help to check the result after the open and the read commands.
Best,
Mark
--
Economy-x-Talk
Consultancy and Software Engineering
http://economy-x-talk.com
http://www.salery.biz
Get your store on-line within minutes with Salery Web Store software.
Download at http://www.salery.biz
Op 26-sep-2006, om 19:36 heeft Robert Sneidar het volgende geschreven:
This script was working on a PowerPC based G4 laptop. I dropped the
laptop whacking the backlight, but that is another story. I was
able to import all my programs and data to a brand spanking new
Intel Macbook Pro. Now this script is NOT working. THE IT variable
does NOT CHANGE when I read from a file! It remains the path to the
file I chose in the answer file dialog. Is read from file broken
for the Intel machines??
ON mouseUp
breakpoint
answer file "Select the program file to import:" of type "F+PR"
put it into mfile
IF mfile is empty THEN exit mouseup
put slyfilefrompath(mfile) into mshortfile
IF char -4 of mshortfile is "." THEN
put char 1 to -5 of mshortfile into mmodule
END IF
IF there is a card (mmodule) THEN
go card (mmodule)
ELSE
new card
set the name of this card to tolower(mmodule)
END IF
-- here is the important part
open file mfile
read from file mfile at 1 until END
-- at this point it still contains the result of the answer
file dialog!!!!! EEEEEEKKKKKK!!!!!!
put it into field code
-- close file mfile
set the text of field "lblcode" to "Code: " & slyfilefrompath
(mfile)
END mouseUp
I was able to get the URL functionality working. I used:
put "file:" & mfile into mfilepath
put url mfilepath into field code
But other programs I use depend on reading from a low level file.
Bob Sneidar
IT Manager
Logos Management
Calvary Chapel CM
_______________________________________________
use-revolution mailing list
[email protected]
Please visit this url to subscribe, unsubscribe and manage your subscription
preferences:
http://lists.runrev.com/mailman/listinfo/use-revolution