Compartilhar via


Determining Where to Build a Custom Application

You can build and store custom ASPX pages and Web applications in the following directory, which supports the _layouts virtual directory:

Local_Drive:\Program Files\Common Files\Microsoft Shared\Web Server Extensions\60\TEMPLATE\LAYOUTS

Pages in this directory are accessible from all Web sites in the Windows SharePoint Services deployment through a URL in the following form:

http://Server_Name/[sites/][Site_Name]/[SubSite_Name]/[...]/_layouts/File_Name.aspx

For code that involves use of only the Microsoft.SharePoint.Administration namespace for working with global settings in a Windows SharePoint Services deployment, it is recommended that the Web application be created on the administrative port. Build and store ASPX pages and Web applications for the administrative port in the following directory:

Local_Drive:\Program Files\Common Files\Microsoft Shared\Web Server Extensions\60\TEMPLATE\ADMIN\1033

Pages in this directory are accessible through a URL in the following form:

http://localhost:Port_#/File_Name.aspx

For information on how to create a Web application in Microsoft Visual Studio .NET that runs in the context of Windows SharePoint Services, see Getting Started with Customizing a SharePoint Web Site in Visual Studio .NET.

Note  You cannot use custom code inline within the native pages of Microsoft Windows SharePoint Services that are used for working with lists or sites.

Console applications can be created anywhere on the front-end Web server. For information on creating a console application that runs in the context of Windows SharePoint Services, see Creating a Console Application.