比如我在web.config有句话
<add key="DBtype" value="Accsee"/>然后我在.cs页面有句代码是这样的: string Path_db = ConfigurationManager.AppSettings["DBPath"];为什么path_db得到的值的是“data\doughty_bbs.mdb”,而不是access
<add key="DBtype" value="Accsee"/>然后我在.cs页面有句代码是这样的: string Path_db = ConfigurationManager.AppSettings["DBPath"];为什么path_db得到的值的是“data\doughty_bbs.mdb”,而不是access
你的代码写错了应该是
string Path_db = ConfigurationManager.AppSettings["DBtype"];
DBtype才是Key
cs 代码里 应该是
string Path_db = ConfigurationManager.AppSettings["DBtype"];