Path an InfoPath Form was opened from?

M

Marcel Graf

Is there a function in VBScript/JScript which gets you the path an InfoPath
2003 Form was opened from? Something like ThisWorkbook.Path or DB.Name in MS
Access/VBA.

My setup is as follows: In a local folder I have one InfoPath Form (XSN
file) and 4 PDF files. The form contains 4 buttons which must open one of the
PDFs when clicked on. I wrote a code for this which works fine with the PDF
filepaths hardcoded. But as soon as I move the form and the PDFs to another
folder, this won't work anymore.

So I would prefer to build up the PDF filepaths in the code, based on the
folder where my form is opened from. But I found no way how to get this
folder in the code.

All I was able to get is the network folder where the original of my form is
stored and published. But as the form is mostly used offline this doesn't
really help me.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top