1
votes

All I want to do is duplicate the notes (don't need an upload control)

KeyFileName = WS.OpenFileDialog(False, "Select Key file", "Workflo Systems Key File|*.wfs")

I simply need the filename and path and want the user to only be able to select a file with a given extension. This is a piece of cake in LS but have not been able to find a way to do this in SSJS. Found several instances of requests for this functionality but not much in how to accomplish it.

1
I started digging around this functionality a few months ago but never got very far. But to the best of my knowledge, you will need to use Java Swing: docs.oracle.com/javase/7/docs/api/javax/swing/JFileChooser.htmlMichael G. Smith

1 Answers

2
votes

This might depend on your browsers. If they are html5 compatible then check this out: http://www.html5rocks.com/en/tutorials/file/dndfiles/

Since XPages includes Dojo then maybe this will help there: https://dojotoolkit.org/reference-guide/1.8/dojox/form/FilePickerTextBox.html

Regardless you're going to need to do something with Client Side javaScript I'm sure.

Good Luck!