Hi, I have the following code that I am using to create a new Form with data from xmlPath using the template in templatePath. When I execute the code as it is below, I get an error: Script error, the parameter is incorrect".
Sub generateTestResults_OnClick(eventObj)
xmlPath = "C:\temp\CRS_51606_page_check_output.xml"
templatePath = "C:\temp\pdfTestResults.xsn"
set objXDoc = Application.XDocuments.NewFromSolutionWithData(xmlPath,templatePath)
End Sub
However, when I put the strings into the NewFromSolutionWithData method like so:
set objXDoc = Application.XDocuments.NewFromSolutionWithData("C:\temp\CRS_51606_page_check_output.xml","C:\temp\pdfTestResults.xsn")
it works fine! I need to be able to build these strings dynamically at runtime, so using the variables is important. Can someone help?
Thanks,
Paul