Saving via Save Button

R

Ralf Erdmann

Hello,

how do I save my infopath document on a specified path with a Command Button
in VBscript code. I made some tries with PerformSaveOperation
but always got Runtime Errors.

Can someone help me please ?

Thx in advance

Ralf
 
F

Franck Dauché

Hi Ralf,

Did you try: XDocument.SaveAs(your path)
Form will need to be Full Trust

Regards,

Franck Dauché
 
A

AlexW

I am having the same problem. The form is fully trusted. I get the message
"Infopath cannot complete this action because of an error in the form's
code."
The code is:
Sub CTRL429_6_OnClick(eventObj)

XDocument.UI.Alert("Saving form...")
XDocument.SaveAs("D:\MyForm.xml")

End Sub

Thanks,
Alex
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top