|
So the basics of my app are completed, everything i'll need is complete (except directplay server) and it works, perfectly i might add. but it only works on MY computer whenever i try to run it on another it exits with a error code and a text saying: "Failed security policy check". if i try to run the app from my comp but from another computer's drive (via lan) the debbuger kick in and i get the above message+ "Unverifiable assembly". google had ssomething to say about the problem but i don't know how to implement the solution found there:
"A temporary method of solving this issue is to simply give the LocalIntranet
zone more trust. This can be done in the .NET Framework Configuration
control panel applet. A permanent solution is to modify your security policy
to give FullTrust to all assemblies signed with your key."
to the problem as stated there (which i think is my problem):
"If you're running (and remote debugging) your app from a local network
share, then I suspect that you're running into a permissions issue. Programs
that run on the CLR use something called code access security (CAS), which
assigns trust based upon evidence it can gather from the code itself. This
evidence is then compared against the security policy, and a permission
grant is generated."
anyway i'll be including the debug output when i run the app on another conputer, i hope that my post isn't too long and boring.
"'forms.exe': Loaded '\\Homepc\2games (d)\forms\Debug\forms.exe', Symbols loaded.
'forms.exe': Loaded 'C:\WINDOWS\system32\ntdll.dll', No symbols loaded.
'forms.exe': Loaded 'C:\WINDOWS\system32\mscoree.dll', No symbols loaded.
'forms.exe': Loaded 'C:\WINDOWS\system32\kernel32.dll', No symbols loaded.
'forms.exe': Loaded 'C:\WINDOWS\system32\advapi32.dll', No symbols loaded.
'forms.exe': Loaded 'C:\WINDOWS\system32\rpcrt4.dll', No symbols loaded.
'forms.exe': Loaded 'C:\WINDOWS\system32\user32.dll', No symbols loaded.
'forms.exe': Loaded 'C:\WINDOWS\system32\gdi32.dll', No symbols loaded.
'forms.exe': Loaded 'C:\WINDOWS\system32\shlwapi.dll', No symbols loaded.
'forms.exe': Loaded 'C:\WINDOWS\system32\msvcrt.dll', No symbols loaded.
'forms.exe': Loaded 'C:\WINDOWS\Microsoft.NET\Framework\v1.1.4322\mscorwks.dll', No symbols loaded.
'forms.exe': Loaded 'C:\WINDOWS\Microsoft.NET\Framework\v1.1.4322\msvcr71.dll', Symbols loaded.
'forms.exe': Loaded 'C:\WINDOWS\Microsoft.NET\Framework\v1.1.4322\fusion.dll', No symbols loaded.
'forms.exe': Loaded 'C:\WINDOWS\system32\shell32.dll', No symbols loaded.
'forms.exe': Loaded 'C:\WINDOWS\WinSxS\x86_Microsoft.Windows.Common-Controls_6595b64144ccf1df_6.0.2600.2180_x-ww_a84f1ff9\comctl32.dll', No symbols loaded.
'forms.exe': Loaded 'C:\WINDOWS\system32\comctl32.dll', No symbols loaded.
'forms.exe': Loaded 'C:\WINDOWS\Microsoft.NET\Framework\v1.1.4322\mscorlib.dll', No symbols loaded.
'forms.exe': Loaded 'C:\WINDOWS\assembly\NativeImages1_v1.1.4322\mscorlib\1.0.5000.0__b77a5c561934e089_49459abc\mscorlib.dll', No symbols loaded.
'forms.exe': Loaded 'C:\WINDOWS\Microsoft.NET\Framework\v1.1.4322\mscorsn.dll', No symbols loaded.
'forms.exe': Loaded 'C:\WINDOWS\system32\urlmon.dll', No symbols loaded.
'forms.exe': Loaded 'C:\WINDOWS\system32\ole32.dll', No symbols loaded.
'forms.exe': Loaded 'C:\WINDOWS\system32\version.dll', No symbols loaded.
'forms.exe': Loaded 'C:\WINDOWS\assembly\GAC\System\1.0.5000.0__b77a5c561934e089\System.dll', No symbols loaded.
'forms.exe': Loaded 'C:\WINDOWS\assembly\NativeImages1_v1.1.4322\System\1.0.5000.0__b77a5c561934e089_70640dd3\System.dll', No symbols loaded.
'forms.exe': Loaded 'C:\WINDOWS\assembly\GAC\System.Drawing\1.0.5000.0__b03f5f7f11d50a3a\System.Drawing.dll', No symbols loaded.
'forms.exe': Loaded 'C:\WINDOWS\assembly\NativeImages1_v1.1.4322\System.Drawing\1.0.5000.0__b03f5f7f11d50a3a_842e96f6\System.Drawing.dll', No symbols loaded.
The thread 'Win32 Thread' (0x1c0) has exited with code 0 (0x0).
'forms.exe': Loaded 'C:\WINDOWS\Microsoft.NET\Framework\v1.1.4322\diasymreader.dll', No symbols loaded.
'forms': Loaded 'c:\windows\microsoft.net\framework\v1.1.4322\mscorlib.dll', No symbols loaded.
'forms': Loaded 'c:\windows\assembly\gac\system\1.0.5000.0__b77a5c561934e089\system.dll', No symbols loaded.
'forms': Loaded 'c:\windows\assembly\gac\system.drawing\1.0.5000.0__b03f5f7f11d50a3a\system.drawing.dll', No symbols loaded.
An unhandled exception of type 'System.Security.Policy.PolicyException' occurred in Unknown Module.
Additional information: Unverifiable assembly '\\Homepc\2games (d)\forms\Debug\forms.exe' failed policy check.
The thread 'Win32 Thread' (0x218) has exited with code -532459699 (0xe0434f4d).
The program '[3192] forms.exe: forms' has exited with code 0 (0x0).
The program '[3192] forms.exe: Native' has exited with code 0 (0x0)."
m$: It is normal for your screen to go blank and for your computer to restart itself several times
|
|
|
|
|
You should start reading about CAS (code access security).
MSDN has some articles on the topic that will help you learn how your application behaves differently when run from an untrusted source (for example, a mapped network drive).
Regards,
mav
|
|
|
|
|
i don't really want to know how the app behaves i just want it to run, how can you make an untrusted source trusted so my program can run properly, i really need this program to run on just a couple of computers so modifying stuff would be posible but what do i need to modify?
i've read something realted to my problem but i have no ideea as to how i could generate the certificates required or integrate them inot my code
m$: It is normal for your screen to go blank and for your computer to restart itself several times
-- modified at 7:36 Tuesday 3rd January, 2006
|
|
|
|
|
navvara the infantryman wrote: don't really want to know how the app behaves i just want it to run,
This is a heavily misguided response to a perfectly reasonable answer to your question. Your problem is related to Code Access Security - a feature of the .NET framework - if you dont care to understand for yourself an important feature you are working with then don't expect any more help from the kind people here.
|
|
|
|
|
if my reply was abusive then i am sorry it's just the result of seing my work waste away when i thought it was completed and running perfectly + not having time to read all that documentation as my project is due on monday
what i should have wrote is "i'm a dummy and don't know what all that means have you got a straightforward solution? (magic bullet, something simple?)"
PS: from what i have read my app's assembly is checked when run but i don't know even if my app has one or how to make one or check it
m$: It is normal for your screen to go blank and for your computer to restart itself several times
-- modified at 8:00 Tuesday 3rd January, 2006
|
|
|
|
|
I didnt say it was abusive, I said it was misguided.
|
|
|
|
|
|
Hi all, i need to call the Windows XP File Properties window from my application (giving it the path of the file or folder to open its roperties window)
Hints:
1- my application is in VB.Net
2- operating system : Windows XP Prffessional
Please, if any one could help, reply me as soon as possible
Thank u all
|
|
|
|
|
First u posted in C# forum ur vb.net question but anyway here is one example
http://www.kdkeys.net/forums/678/ShowPost.aspx
|
|
|
|
|
First: Sorry for posting in the wrong forum, but i posted my question in the VB.Net forum also if any one need to continue the discussion there.
Seconed: It was not my question "How to find a file/or Folder properties?"
i mean how to call the actual 'File/Folder Properties Window' embeded in Windows XP OS
Thank u
|
|
|
|
|
I am having UserControl1.ascx and WebForm1.aspx Files in my project. I have included Usercontrol1.ascx in WebForm1.aspx page. UserControl1.ascx contains Login Info (user name, password and login sumit button) and the fields are validated with requiredfield validator. webform1.aspx contains registration details and submit button. here also the fields are validated with requiredfield validator. now, if i press the login button of usercontrol1.ascx the registration fields are getting validated and also if i press registration form submit button the login fields are getting validated. what i want is the login submit should validate only (username and password) and registration submit button should validate only the registration form fields. how do i resolve this problem. pls. help me out...
|
|
|
|
|
Hi,
Make both the validator enable = false on webform page load event write the following code.
//declare instance for required field validator
RequiredFieldValidator rv1 = new RequiredFieldValidator();
//declare instance for usercontrol
System.Web.UI.UserControl wui = new UserControl();
//find the usercontrol
wui = (System.Web.UI.UserControl)(this.FindControl("WebUserControl11"));
//find the requiredfield validator (which is in usercontrol)
rv1 = (System.Web.UI.WebControls.RequiredFieldValidator)(wui.FindControl("RequiredFieldValidator1")); //searching usercontrol requiredfield validator
button click event (this is in webform) write the following code
req1.Enabled = true;// this requiredfield validator is in your webform
RequiredFieldValidator r1 = new RequiredFieldValidator();
System.Web.UI.UserControl wui = new UserControl();
wui = (System.Web.UI.UserControl)(this.FindControl("WebUserControl11"));
r1 = (System.Web.UI.WebControls.RequiredFieldValidator)(wui.FindControl("RequiredFieldValidator1"));
req1.Validate();
if (IsValid)
{
r1.Enabled = false;
--statement--
}
************* user control **************
usercontrol page load event write the following code
RequiredFieldValidator reqq1 = new RequiredFieldValidator();
reqq1 = (System.Web.UI.WebControls.RequiredFieldValidator)(Page.FindControl("req1"));
reqq1.Enabled = false;
RequiredFieldValidator1.Enabled = false;
reqq1.EnableClientScript = false;
RequiredFieldValidator1.EnableClientScript = false;
usercontrol button click event write the following code
RequiredFieldValidator1.Enabled = true;
RequiredFieldValidator reqq1 = new RequiredFieldValidator();
reqq1 = (System.Web.UI.WebControls.RequiredFieldValidator)(Page.FindControl("req1"));// searching webpage requiredfield validator
RequiredFieldValidator1.Validate();
if(RequiredFieldValidator1.IsValid)
{
reqq1.Enabled = false;
--statement--
}
Thanks
Warm Regards
Prakash-B
|
|
|
|
|
hello
i want to create new SmartDeviceApplication .
the Emulator apper but my form dose not.
Pleeeeeeeeeease help me soon as you can
Ramiforu2002@hotmail.com
Ramiforu2002@yahoo.com
Rami Alkhalyleh
Rami Alkhalyleh
|
|
|
|
|
could anybody teach me how to implement the code about auto detect web drive's status of connect/disconnect and also connect/disconnect function ? thanks very much !
|
|
|
|
|
R2409 wrote: web drive's
What's a "web drive"?
ColinMackay.net
"Man who stand on hill with mouth open will wait long time for roast duck to drop in." -- Confucius
"If a man empties his purse into his head, no man can take it away from him, for an investment in knowledge pays the best interest." -- Joseph E. O'Donnell
|
|
|
|
|
sorry , I just mean the network drive being shared by network form other computer ! (ps . or it should named as mapped drive )
|
|
|
|
|
Hey,
do anyone know of any good basic articles about designing / creating a GUI in Visual Studio 2005 ?
What i am wondering is the basic techniques for switching content and stuff like that depending on what you choose in a menu (etc.).
I dont really get if you create a Panel and throw all your stuff for one MenuItem on it, and then when you choose in the menu, you just simply switch the panels ?
Or how is it done ?
Hope someone can help
Martin
|
|
|
|
|
|
Is there a way to disable the [x]that closes the form (upper-right corner)?
|
|
|
|
|
add
this.ControlBox= false;
in the InitializeComponent() function or u can directly disable this in the windows style property of the form
sathy
|
|
|
|
|
I'm trying to access my forms (Form1) child objects, such as panels, sliderbars, toolbars, etc from a second class that i've added to the project.
Currently i'm accessing Form1 via Form1.ActiveForm the problem that i'm having is that i can access the standard stuff from the form class, but nothing else, is this because Form1 is a public class, and all the child objects are private?
if this is the case is it safe for me to change only the objects that i need to access to public, or is that unsafe coding?
Is there a better way?
or am i just going about this all wrong?
|
|
|
|
|
Is it safe? Yeah.
Is it proper coding practice? No way!
Your second class shouldn't know anything about the form that called it. Your Form should be passing the data it needs to to the class methods and processing any return data required. Your second class should not be trying to modify the form, or read from it, at all.
RageInTheMachine9532
"...a pungent, ghastly, stinky piece of cheese!" -- The Roaming Gnome
|
|
|
|
|
JstDaNuGuy wrote: if this is the case is it safe for me to change only the objects that i need to access to public, or is that unsafe coding?
You should not make any field in a class public. See this article on Why make fields in a class private, why not make them public?[^]
JstDaNuGuy wrote: Is there a better way?
Yes. But it depends on what you are trying to do. What is the purpose of the second class? And what is the reason for the interaction?
ColinMackay.net
"Man who stand on hill with mouth open will wait long time for roast duck to drop in." -- Confucius
"If a man empties his purse into his head, no man can take it away from him, for an investment in knowledge pays the best interest." -- Joseph E. O'Donnell
|
|
|
|
|
thanks for the information guys...
what im' trying to do is set the form state upon load then save on exit. but i have much more to set/save than just the form size, and i was just trying to do it from a different class
i'm still learning...
|
|
|
|
|
i want to run a file past to my function with the default program reader, that is:
if the file passed is a .xls run that file in Microsoft Excel,
if it is a .gif run the file in the Windows Image Preview
if it is an .html run the file with Explorer, and so on...
|
|
|
|