UseScript property

pinPDF

UseScript property


knguyenduy 10-01-2009, 1:46
Hello,

We set the UseScript property to true and everything works perfectly on our local machine. When we put this code to production, it doesn't work. What can I do ?

Thanks for your help.

Nguyen

Re: UseScript property


Pintexx Support 10-02-2009, 8:04
Hello,

are there error messages ?

Regards,
Hans-Peter

Re: UseScript property


knguyenduy 10-02-2009, 9:47
There are no error messages. We have windows server 2003 and Internet Explorer 6. The internet explorer enhanced security configuration is enabled on the server and scripts are disabled for internet browsing.

Re: UseScript property


Pintexx Support 10-05-2009, 9:03
That might be the problem as pinPDF uses IE for conversion.

Do you use code like this:
If Not objPdf.Process Then
response.write(objPdf.ErrorMessage)

What does objPdf.ErrorMessage say ?


Here are some more hints:
Firewalls and proxy servers can present particular problems for URL rendering because they may require some kind of logon. Your IIS user will most likely not have a logon. You need to allow pinPDF to logon automatically.

Windows Authentication can produce a challenge that your IIS user may not be responding correctly to. You will find details of how to manage Authentication in the documentation.

Windows 2003 Server defaults to an Internet Explorer Security policy which may interfere with HTML rendering. You may have to modify or disable the policy to allow access to the pages you want to render. If you wish to remove the security component you can do so using the "Windows Components" section of the "Add & Remove Programs" control panel.

If this doesn't help...

First work through some simple sanity checks and common causes of this type of issue.

Do ensure you can browse to the appropriate location using IE while logged on as Administrator. Make sure IE doesn't throw up any blocks or warnings. pinPDF requires a clear route through to the page.

If you're rendering a URL on your localhost then ensure that the IIS user has read access to this location.

Lack of access to the windows/temp directory is a frequent cause of this type of issue. Ensure that your IIS user (eg ASP.NET or IUSR_MACHINENAME) has read/write permission and also (if it fits with your security policy) the ability to create folders. You may also find that ASP.NET is being denied access to its own preferences (eg C:\Documents and Settings\MACHINENAME\ASPNET).
It is our experience that it is surprisingly common for web servers not to be able to resolve URLs to themselves. This means that when testing using an IP address your code will work but when you try and render a web page on the local server using a URL you may get issues.

Regards,
Hans-Peter

Re: UseScript property


knguyenduy 10-06-2009, 10:07
Thank you very much for your response. I shall check these points.
Regards

Re: UseScript property


knguyenduy 10-07-2009, 1:48
Hello,

I get no error message because objPdf.Process returns true and the pdf document has been gererated. The content that is displayed by javascript functions is present in the html page. It's absent in the generated pdf document.

The html file is on the same server and anonymous access is enabled. When I type http://localhost/.../render.html on the server, the file is correctly dispayed.

IUSR_MACHINENAME has read/write permission on the windows/temp directory and can create folders. I don't understand the phrase "ASP.NET is being denied access to its own preferences".

Internet Explorer Security policy is enabled on the server but the html file is on the same server and javascripts are enabled for http://localhost and https://localhost.

I don't know what to do.

Regards.

Re: UseScript property


Pintexx Support 10-08-2009, 8:07
Hello,

which IE version do you run at server ?

Regards,
Hans-Peter

Re: UseScript property


knguyenduy 10-08-2009, 9:29
IE 6.0.3790.1830
Windows server 2003

Re: UseScript property


Pintexx Support 10-08-2009, 1:57
Hello,

it is definitivly a rights issue.

pinPDF uses IE for conversion.

Could you please remove/disable Internet Explorer Security policy just for test ?

Do you convert the url or do you read content of file into a string ?

If you use an URL: Do you use localhost or the IP address ?


Regards,
Hans-Peter

Re: UseScript property


knguyenduy 10-09-2009, 9:24
Hello,

Thanks for your quick response.

I've removed Internet Explorer Security (without restarting the server) but javascript is still not working.

I use URL to render pdf document (http://localhost/..../file.html)

Regard,

Re: UseScript property


Pintexx Support 10-12-2009, 8:39
Hello,

is there a difference when using IP address or when using a file reference like

file:///c:/inetpub/...

Regards,
Hans-Peter

Re: UseScript property


knguyenduy 10-13-2009, 10:41
I don't use the file reference beacause it's not the same on different environnments.
Regards,
Nguyen

Re: UseScript property


Pintexx Support 10-13-2009, 1:45
I know.
It is only for testing.

Regards,
Hans-Peter

Re: UseScript property


knguyenduy 10-13-2009, 5:45
It's difficult to test this because we have 1 compilation/week and we have to validate the server this week. I'll test file reference later and shall reply to you soon. At the moment I remove all javascript functions in the html file.
Thanks very much for your help.

Regards,
Nguyen