Your achievements

Level 1

0% to

Level 2

Tip /
Sign in

Sign in to Community

to gain points, level up, and earn exciting badges like the new
Bedrock Mission!

Learn more

View all

Sign in to view all badges

Force PDF form to open in browser?

Avatar

Level 4

I'm just wondering if it is possible to force a pdf file to open in a web browser. So that, if the file is saved to someone's computer, when you open it, it automatically opens in the web browser

Thanks,


Nik

0 Replies

Avatar

Level 8

Of course you can set the target operating system to associate the pdf extension with a web browser but I think you're probably looking for the form itself to be able to control that regardless of operating system.

If so, try putting this in the top level subform's docReady event:

if (!event.target.external){

cURL=event.target.path;

cURL=cURL.replace(/\/(\w)\//,"$1:/");

app.launchURL(cURL,true);

event.target.closeDoc();

}

Adobe will show you a warning to Cancel or Allow but that can't be supressed for security reasons.

Kyle