المساعد الشخصي الرقمي

مشاهدة النسخة كاملة : problem reading from app.config



C# Programming
09-20-2010, 04:30 AM
I have added an app.config file in my winform aplicaion an added one key

<add key="IsFirstRun" value="True" />

then I am tying to read it like this:
MessageBox.Show(ConfigurationManager.AppSettings["IsFirstRun"].ToString());

but I am getting this error:
Configuration system failed to initialize

on the MessageBox line..

why? how ca I fix please?