Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations TouchToneTommy on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Save form gives run error 1

Status
Not open for further replies.

petermeachem

Programmer
Aug 26, 2000
2,270
GB
Have taken the plunge and decided to learn vb.net using the express ed.

I started a new project, popped a webbrowser control on the form, told it to display the bbc, clicked Run and all was fine and dandy.

I then saved the project, clicked Run again and I get an error. The error details include

threw an exception of type 'System.Security.SecurityException'

What's all this about? I can't find any simple explanation online.
 
You probably saved the project to a network drive (check if your documents & settings folder is mapped to a network drive)

You have three options: 1) save your project locally. 2) Tell .Net to explicitly trust that assembly. 3) Raise .Net's trust level for Local Intarnet to full.

To alter your .Net trust level, go into Control Pannel\Admin Tools. You should see a .Net Wizard option in there. Launch that and you should get a small window with three options. Use "Adjust .Net Security" to increase the trust level, or "Trust an Assembly" to trust this specific app. Both of the wizards are pretty straight forward.

-Rick

VB.Net Forum forum796 forum855 ASP.NET Forum
[monkey]I believe in killer coding ninja monkeys.[monkey]
 
Thanks, that pointed me in the right direction. Except that I have .net 2 so I selected My Computer, Runtime Security Policy, Code Groups, All Code. Then Edit Code Group Policies, then Permission Set and selected Fulltrust.

I must say I have no idea what any of this means. The important thing is it now works and didn't before.

Onwards and upwards.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top