Perspective Scripting system.file

The online manual shows some of the system.file functions are available in Perspective Session scope. I am having trouble getting them to work in a button click event. Are these not available in a browser session?

Which function are you trying to use?

I have tried a few of them with no luck. But for an example, the system.file.openFile() function.

When I try to put this example code in a button click event:
path = system. file .openFile( 'gif' )

Nothing happens. When I put this in a vision window button, I get an open file dialog.

Yeah, that one isn’t going to work. Nothing that would cause a UI or popup to appear will work.

We need to remove those from the autocomplete list if they are showing up as available.

Ok, thanks for the reply. Is there any alternative I can use? I’m trying to allow users to upload xml files to a database.

I’m not familiar enough with all the Perspective stuff to answer that, someone else will have to come along and chime in. I’m sure they’ve considered this, just not sure whether a solution exists yet or not.

No problem. Also, I just checked the auto-complete list and those functions are not in the list. I was referring to the online manual under syntax where is says “Scope: Gateway, Vision Client, Perspective Session”.

As of right now, there’s no way to upload through Perspective. I know some of the developers on the Perspective team are considering adding the functionality. (As for downloading files, you can currently pair Perspective with Web Dev and serve files through a Web Dev endpoint.)