locked
Help with caspol/.NET not working?! RRS feed

  • Question

  • Hi.

    I can't get any .NET programs to work I've compiled all of a sudden. I'm not sure really when this started, but basically, all apps I've developed in VB.NET won't run outside the IDE.
    They display a box saying it couldnt preform the request, and to use the .NET configuration tool to give it permission.
    I've tried to use Caspol, but I don't feel like enabling it for EVERY app I make, this would take too long.
    It wasnt like this before, so I dunno whats up, but this is getting really annoying. I am using .NET 3.5.
    The only thing that seems to work is caspol -s off, but it won't let me keep it off, obviously.

    How do I fix this? It's getting REALLY annoying, I can't even run a blank windows forms application!

    Also, I have not messed with caspol or anything else before this happened, infact I had to search around to even find the dang thing.

    Thanks!
    Visual Basic 6.0 & VB.NET
    Monday, March 30, 2009 9:43 PM

Answers

All replies

  • So you're able to run all the application via VS IDE, right?

    What is the exact error message?

    What about logging into another Windows Account with Admin privilege?

    Thanks.
    Please remember to mark the replies as answers if they help and unmark them if they provide no help.
    Welcome to the All-In-One Code Framework! If you have any feedback, please tell us.
    Wednesday, April 1, 2009 9:17 AM
  • 1) Yes, the application works fine when run from the IDE.

    2) It's long, so I screenie'd it: http://img19.imageshack.us/img19/341/neterror.png

    3) ...A matter infact, yes, my other admin account runs it fine and without error. However, my current account is Admin too, so I dunno whats up with that.

    Also, it works fine on my other computer.

    P.S. thx for you reply
    Visual Basic 6.0 & VB.NET
    • Edited by Jaxbot Wednesday, April 1, 2009 12:12 PM typo
    Wednesday, April 1, 2009 12:11 PM
  • Hi Jaxbot

    You can either utilize the .NET configuration tool (more information, see: http://msdn.microsoft.com/en-us/library/2bc0cxhc.aspx) or caspol.exe tool (see: http://msdn.microsoft.com/en-us/library/cb6t8dtz.aspx) to modify security policy.

    As you're able to log in other local admin account to run the application, you can try to return the security policy settings to the default.
    Use caspol.exe as:
    caspol -user –reset
    (You can undo the reset using the –recover option if no further policy changes are made after the –reset call.)

    For your reference:
    How to: Return to the Default Security Policy Settings Using Caspol.exe
    http://msdn.microsoft.com/en-us/library/bk67a586.aspx

    Thanks.
    Please remember to mark the replies as answers if they help and unmark them if they provide no help.
    Welcome to the All-In-One Code Framework! If you have any feedback, please tell us.
    • Marked as answer by Jaxbot Thursday, April 2, 2009 11:48 AM
    Thursday, April 2, 2009 3:46 AM
  • Worked perfectly, thanks!
    Visual Basic 6.0 & VB.NET
    Thursday, April 2, 2009 11:48 AM