Search content:

 

Personal Menu
Username:
Password:
Save password

Become a member

Forgot Password?

 

Don't miss these
Advanced Lingo for Games
Vector Shape - Create Star
DriveInfo
Shadow Maker
Convert Data
Animate Text By Font Size
DirectSound Xtra
JTMR Image to Text
Calculating the day of the date
MPEGXtra
MediaMacros Xtras Mall
 

 

 

Behavior Import Save File From Command Line

Added on 12/19/1999

 

Compatibilities:
D7 D8 Mac PC Script Shockwave

Rating:

Author: MediaMacros (website)

This script will import a file that is dragged onto the projector"s icon using the command line args.

--Copyright 1999 Chuck Neal
--chuck@mediamacros.com
--If you find this code helpful, send me an e-mail and let me know. :-)

on checkString me
  acceptedTypes = ["txt", "doc"]
  theFile = the commandLine
  theChars = theFile.char.count
  if theFile <> "" and acceptedTypes.getOne(theFile.char[(theChars - 2)..theChars]) <> 0 then
    --is a valid file dropped or clicked
    myFile = new(xtra "fileIO")
    openFile(myFile, theFile, 1)    
    theText = readFile(myFile)
    closeFile(myFile)
    return theText
  end if
end

on getBehaviorDescription me
  return "Call this handler to return the text of a file that started your projector. Change the acceptedTypes list to the extensions you want to use. For more advanced use you can use the file association script in the commercial Buddy API library to allow saved files to be double clicked and start automatically."
end

 


Upload Provided by ABCUpload ASP

Contact

MMI
22 West Court Sq
Suite 2C
Newnan, GA 30263
USA

Fax - (206) 339-5833

Send e-mail