Think of something that you wish Authorware could do but it doesn't?  Let the our good friends at Macromedia know via the wishlist.

Please let us know if you find any of the materials on this site inappropriate or offensive. Please include the url and why the material should be reviewed.

Comments and questions about the site are also welcome. Please no Authorware questions, use the AWARE list.

Back

B5017 - How do I manipulate external files so that they're not easily seen by users?

by - Joseph Ganci


I'd like to use external .gif files but I don't want to make it easy for users to double-click the .gif files and open them up. I wonder if there is any way to have Authorware change the extension of all .gif files in the current folder to have an extension of .ugl and vice-versa?

Here's a script to do convert .gif files to .ugl files:

files := Catalog(FileLocation, "f")
repeat with i := 1 to LineCount(files)
   file := GetLine(files, i)
   extension := SubStr(file, RFind(".", file), CharCount(file))
   if extension = ".gif" then RenameFile(FileLocation^file, ¬
      Replace(extension, ".ugl", file))
end repeat

To change the .ugl files back to .gif:

files := Catalog(FileLocation, "f")
repeat with i := 1 to LineCount(files)
   file := GetLine(files, i)
   extension := SubStr(file, RFind(".", file), CharCount(file))
   if extension = ".ugl" then RenameFile(FileLocation^file,¬
       Replace(extension, ".gif", file))
end repeat

There are 0 reviews
Add your review
Back