Install the form?

C

Chris

Hi

I'm in the process of making an InfoPath form, using Visual Studio 2005
for the coding. I've added a button which is supposed to send email.
However, when I click it, I get the error "That assembly does not allow
partially trusted callers." I've had a look around and have been told
to set the form's security level to Full Trust. However, doing that
gives me this message:

InfoPath cannot grant the Full Trust security level when previewing
unregistered forms. This form will be previewed using the Domain
security level. Any object model calls that are permitted only in fully
trusted forms will fail.
To test the form at the Full Trust security level, close the previewed
form and then install it on your computer.

Install it on your computer? It's already on my computer! I'm lost,
what should I do?

Thanks
Chris
 
C

Chris

Solved. I executed the following in cscript (Windows Script Host):

oApp = WScript.CreateObject("InfoPath.ExternalApplication");
strAbsolutePath = "D:\\Path\\To\\manifest.xsf";
oApp.RegisterSolution(strAbsolutePath,"overwrite");

Hopefully this helps someone :)
Chris
 

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