×
INTELLIGENT WORK FORUMS
FOR COMPUTER PROFESSIONALS

Log In

Come Join Us!

Are you a
Computer / IT professional?
Join Tek-Tips Forums!
  • Talk With Other Members
  • Be Notified Of Responses
    To Your Posts
  • Keyword Search
  • One-Click Access To Your
    Favorite Forums
  • Automated Signatures
    On Your Posts
  • Best Of All, It's Free!
  • Students Click Here

*Tek-Tips's functionality depends on members receiving e-mail. By joining you are opting in to receive e-mail.

Posting Guidelines

Promoting, selling, recruiting, coursework and thesis posting is forbidden.

Students Click Here

Jobs

file I/O problem

file I/O problem

file I/O problem

(OP)
Hey everyone,

I've been trying to use the fileio Xtra for a project I'm working on, but I'm running into a problem. I'm attempting to simply get the windows "open" dialog box to open for now, but I can't even do that for some reason. The script I modified from a more in-depth script is:

on mouseUp
  global myFile
  set myFile = new xtra("fileio")
  set fileName = displayOpen(myFile)
     openFile(myFile, filename, 1)
end

I based it off of the script at:
http://www.adobe.com/cfusion/knowledgebase/index.cfm?id=tn_3192

After I wasn't able to get my script to open any dialog box, I tried simply using the script directly from that page, and that didn't work either.

Eventually I want to be able to have the user import a w3d scene to be manipulated by the user. I have the manipulation controls working already with a pre-determined w3d object and model.

Thanks for the help,
Anthony

RE: file I/O problem

Try:

--
on mouseUp me
  fileio = new xtra("fileio")
  fileSelected = fileio.displayOpen()
end mouseUp
--

Kenneth Kawamoto
www.materiaprima.co.uk

RE: file I/O problem

(OP)
Hey Kenneth, thanks for the reply.

I tried inserting your code into the button's script and I still have the same problem. I can't get any dialog to pop up. Any ideas what's causing this?

Thanks again,
Anthony

RE: file I/O problem

Do you actually have FileIO Xtra?

Type in the following in the Message window:

put interface(xtra "fileio")

What do you get?

Kenneth Kawamoto
www.materiaprima.co.uk

RE: file I/O problem

(OP)
Yeah, I have it. I got the listing of the fileIO parameters and properties when I typed that in.

-Anthony

RE: file I/O problem

Type in the Message window:

fileio = new xtra("fileio")

Then hit the Return key.

Then type in:

fileio.displayOpen()

Then hit the Return key again.

Do you see the file open dialogue window pops up?

Kenneth Kawamoto
www.materiaprima.co.uk

RE: file I/O problem

(OP)
Using the message window the script worked perfectly. I then went and inserted the exact script into the on mouseUp script for the button and it still won't open the dialog box. I'm really confused as to what's causing this.

-Anthony

RE: file I/O problem

(OP)
I just tried putting the same script to start after an exitFrame message, and that worked fine. Does that help to figure out what the problem is?

-Anthony

RE: file I/O problem

(OP)
So I just came across the reason behind the problem with the button. The button's eventPassMode was set to #passNever instead of #passAlways. Just thought I'd share that in case someone else ran into the same situation as me in the future.

-Anthony

Red Flag This Post

Please let us know here why this post is inappropriate. Reasons such as off-topic, duplicates, flames, illegal, vulgar, or students posting their homework.

Red Flag Submitted

Thank you for helping keep Tek-Tips Forums free from inappropriate posts.
The Tek-Tips staff will check this out and take appropriate action.

Reply To This Thread

Posting in the Tek-Tips forums is a member-only feature.

Click Here to join Tek-Tips and talk with other members!

Close Box

Join Tek-Tips® Today!

Join your peers on the Internet's largest technical computer professional community.
It's easy to join and it's free.

Here's Why Members Love Tek-Tips Forums:

Register now while it's still free!

Already a member? Close this window and log in.

Join Us             Close