Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Mike Lewis on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Run a Javascript in the Link properties to open a new window 1

Status
Not open for further replies.

JimFL

Programmer
Jun 17, 2005
131
GB
Hi,

The original problem I have is that I need to build a pdf that will always open a link in another window. The pdf will be running from a browser and will need to open the file in a new window rather than opening within itself.

I have tried using the Open a File and Open a Weblink option but they have been unsuccessful so I am trying to use the Javascript function as it may give me more control.

I am trying to generate a Javascript action within the Link properties of a PDF that will open another window(which contains the absolute link to a file).

So when I am in the link properties of my link I have the ability to add an action to "Run a Javascript". Once this has been added I can edit the javascript.

This is my javascript that doesnt seem to want to work at the moment and I dont understand why.

window.open(' '_blank');

I would expect this to open a new window but it fails to have any action whatsoever.

However I also looked at this code:

app.launchURL("
This opens the link whereas the last didnt but it doesnt open the link in a new window.

Can anybody point me in the right direction to deliver a piece of javascript that will open a link in a new window?

JimFL
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top