Hi,
i'm trying to run this command from within the SQL but i get this error
'C:\Program' is not recognized as an internal or external command,
operable program or batch file.
here is my code
DECLARE @CONVERT_HTML_TO_PDF VARCHAR(4000)
SET @CONVERT_HTML_TO_PDF = '"C:\Program Files\Microsoft SQL Server\MSSQL15.PRI\MSSQL\monitor_binaries\wkhtmltopdf.exe" "c:\new folder\1.html" "c:\new folder\1.pdf"'
EXEC xp_cmdshell @CONVERT_HTML_TO_PDF
Hi.
If you want to be sure that your query works, I recommend uninstalling wkhtmltopdf and simply reinstalling it in the C:\wkhtmltopdf folder.
Once this is done, modify the query exactly like this: