瀏覽代碼

2006-02-02 Chris Toshok <[email protected]>

	* WebConfigurationManager.cs (GetSection(string,string)):
	implement.


svn path=/trunk/mcs/; revision=56479
Chris Toshok 20 年之前
父節點
當前提交
df3cfac2b0

+ 5 - 0
mcs/class/System.Web/System.Web.Configuration_2.0/ChangeLog

@@ -1,3 +1,8 @@
+2006-02-02  Chris Toshok  <[email protected]>
+
+	* WebConfigurationManager.cs (GetSection(string,string)):
+	implement.
+
 2006-02-01  Atsushi Enomoto  <[email protected]>
 
 	* TrustLevelCollection.cs, CodeSubDirectoriesCollection.cs,

+ 7 - 1
mcs/class/System.Web/System.Web.Configuration_2.0/WebConfigurationManager.cs

@@ -203,7 +203,13 @@ namespace System.Web.Configuration {
 		[MonoTODO]
 		public static object GetSection (string sectionName, string path)
 		{
-			throw new NotImplementedException ();
+			try {
+				_Configuration c = OpenWebConfiguration (path);
+				return c.GetSection (sectionName);
+			}
+			catch {
+				return null;
+			}
 		}
 
 		static _Configuration GetWebApplicationConfiguration ()