Question

i have a really simple asp.net (.net 4) web app. Its a simple Hello World web form app running on WinServer and IIS6 (tried also 7). Authentication is "Windows authentication" I want to convert it with WKHTMLTOPDF to PDF. But i always get an error. When i allow Anonymous access it works. If not i get the error.

wkhtmltopdf.exe --username domain\DELETED --password DELETED http://**/index2.html d:\tmp\test.pdf

Loading pages (1/6) Counting pages (2/6) Resolving links (4/6) Loading headers and footers (5/6) Printing pages (6/6) Done

Exit with code 1 due to http error: 1299

The pdf created tells me: "The function requested is not supported"

Any idea how to solve this?

Was it helpful?

Solution

I don't think you can.

You can add userName and password as options to WKHTMLtoPDF but then you need everybodys passwords which makes that worthless.

But there is a workaround. You can use windows impersonation in IIS and therefore bypass this issue.

See this link on msdn to configure it.

Edit

You need to activate NTML v1 on server, see Cutter1703 comment below.

Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow
scroll top