c# - Exception was unhandled - rethrow exception -


i try rethrow exception, it's not working. 'exception unhandled' error in visual studio.

public keyvalueconfigurationcollection getmyappsetting() {   configuration config;   configurationfilemap configfile;   try   {     configfile = new configurationfilemap(configurationmanager.openmachineconfiguration().filepath);     config = configurationmanager.openmappedmachineconfiguration(configfile);     appsettingssection myappsettingsection = (appsettingssection)config.getsection("xxx/appsettings");     myappsettingsection.sectioninformation.allowexedefinition = configurationallowexedefinition.machinetoroaminguser;     return myappsettingsection.settings;   }   catch (exception ex)   {     logger.fatal("...");     throw;   } } 

this method belong class library, , call console application. please, me.

thanks.

it working expected.

you catch, rethrow exception - not handling rethrown exception. that's why getting error.


Comments

Popular posts from this blog

linux - Using a Cron Job to check if my mod_wsgi / apache server is running and restart -

actionscript 3 - TweenLite does not work with object -

jQuery Ajax Render Fragments OR Whole Page -