Skip to main content

Posts

Showing posts from February, 2007

App_Code, App_Data and Namespace in Asp.net 2.0

Directory App_Code and App_Data in Asp.net 2.0 should be located on the root directory of the website. The shared soured code should be in App_Code directory, and shared data file in App_data Directory. The Asp.net 2.0 compilation environment searches the namespaces whin the App_Code directory. For example, if the namespace of Default.aspx.cs is Test.Site, Default.aspx.cs could find the classes of the same namespaces in the App_Code Directory directly. But if Default.aspx.cs is not in the namespace of Test.Site, it should contain "using Test.Site;".