Applied patch from jira issue - OFBIZ-5721 - Generate pdf doesn't open in new target.
Thanks Pierre for reporting the issue and providing patch for the same. 

git-svn-id: https://svn.apache.org/repos/asf/ofbiz/trunk@1626465 13f79535-47bb-0310-9956-ffa450edef68