Click to See Complete Forum and Search --> : Random in error in ASPT.net with VB NET


yyiiyyii
February 21st, 2007, 03:50 PM
Security Exception
Description: The application attempted to perform an operation not allowed by the security policy. To grant this application the required permission please contact your system administrator or change the application's trust level in the configuration file.

Exception Details: System.Security.SecurityException: Requested registry access is not allowed.

Source Error:


Line 50: dtSoftwareTable.Clear()
Line 51: dtSoftwareTable.Columns.Clear()
Line 52: dAdapter.Fill(dtSoftwareTable)
Line 53:
Line 54:

This error happens at random and the only way to fix it is to reboot the machine

mcmcom
March 1st, 2007, 12:03 PM
maybe this will help

http://support.microsoft.com/kb/329291

hth,
mcm

yyiiyyii
March 6th, 2007, 11:03 PM
nope, that didnt work. also this is a random error so it makes me wonder why it only happens sometimes

Charu0306
March 7th, 2007, 01:19 AM
Obviously, does your user account where your executing the code has registry rights...Like Registrt access is mostly disabled for ALL users , Guests etc...You need to set permission for that from the Administrator mode (logging in as Administrator should help.).

yyiiyyii
March 7th, 2007, 06:04 PM
all the accounts on the machine are a member of the administrator group and have full access to the registery. also if it was truely a security issue i dont know think it would be random then

Charu0306
March 7th, 2007, 06:22 PM
all the accounts on the machine are a member of the administrator group and have full access to the registery. also if it was truely a security issue i dont know think it would be random then


but make sure you are able to access the registrt manually from the Run options.. TRy toe dit the registr and see manually if it allows you access.

The error message clearly says you do not have access to the Registry.

yyiiyyii
March 9th, 2007, 11:09 PM
i can access the registry if i use regedit that is for sure