SharePoint Application and Site Pages - Part 2 of 2
page 3 of 5
by Steven Barden
Feedback
Average Rating: This article has not yet been rated.
Views (Total / Last 10 Days): 28375/ 37

Deploying the application

·         I am now going to make some references to a previous writing I made, called "Developing and Deploying a SharePoint Feature - Part 1".

·         That writing was actually completed very much with this goal in mind, to be used as a basis for pushing SharePoint work by way of Features. Although there are differences between the previous project and this one, which of course will be described, you could basically copy the components from that project into this project to get started. In fact, I suggest you do so, after of course reading the previous article in its entirety.

·         There will be one major difference between the basic Feature article and this one… a menu change. When it comes to this project, you can of course build the application page, and then actually navigate to it via the URL bar, but you are likely at some point going to want to be able to navigate to various pages based on menu options. This adaptation of the Feature project will allow you to add a menu option that can be used to navigate directly to a desired page, in this case the Application page we are building. As a quick peak ahead, you will do this in the elements XML file.

·         The install.cmd page needs only minimal changes.

·         After adding the feature.xml file, open it and change the ID, Title, Description, Version and ImageURL attributes as required.

·         Finally, change the ElementManifests section as the following, <ElementManifests><ElementManifest Location="elements.xml" /></ElementManifests>

·         This concludes the adjustments to the Feature.XML file.

·         Next add an xml file along-side the Feature.XML file, called Elements.XML. This will be used for specific information related to the components, in this case, the Application page we have constructed.

·         If you are using the example code simply review the code, copy and paste it into your project, adjusting it as you see fit.

·         I will not dig deeper into the lines at this time because this should be enough to get you started. Of course I would highly encourage you to review the Microsoft Windows SharePoint Services 3.0 SDK to review all of your options. Hint… search "elements.xml CustomAction"

·         You should now be prepared. Go to a command prompt and run the Install.cmd file. Open a browser to the site you are used to working with and login. Navigate to the settings, Features and turn on your new feature. After a refresh you should see a new option on your drop down menu that should lead to your new Application page.

·         If you find that your needs are to connect to Site pages with menus, instead of Application pages, so long as you know or can build the URL, you can do what you want here as well. A future article I plan to write will cover the act of programmatically, dynamically building menu links to both Application pages and Site pages, but at this point you should be starting down the right track.

·         Smile and be happy… all should be well.


View Entire Article

User Comments

Title: Using an application page as the home page for a team sire   
Name: Shilpa
Date: 2010-04-13 6:05:40 AM
Comment:
Hi,

I am very new to Sharepoint programming.
I have a requirement where a SP list should be populated on loading the team site home page. I understand his is not possible with site pages. But can I create an application page that will populate the list on page load and make the application page the default page for the site?

Your response to this question will be much appreciated

Regards,
Shilpa
Title: VS.NET 2008   
Name: Jagan
Date: 2008-10-09 12:01:54 PM
Comment:
Does that work with VS.NET 2008 + MOSS 2007 ?
Title: Re. E.G.   
Name: T.Holm
Date: 2008-10-03 8:51:14 AM
Comment:
Remarks retracted, didn't see the downloads :)
Title: E.G.   
Name: T.Holm
Date: 2008-10-03 7:22:34 AM
Comment:
It would have been great, if you had made an example (screenshot or literal of the aspx page, including the reference to a code-behind file). Anyway it got me started (in the process of writing an application page to the central adm)
Title: Great   
Name: Abdulla Abdelhaq
Date: 2008-09-22 5:30:29 PM
Comment:
Thank you .. well done :)

Product Spotlight
Product Spotlight 





Community Advice: ASP | SQL | XML | Regular Expressions | Windows


©Copyright 1998-2024 ASPAlliance.com  |  Page Processed at 2024-04-20 10:28:50 AM  AspAlliance Recent Articles RSS Feed
About ASPAlliance | Newsgroups | Advertise | Authors | Email Lists | Feedback | Link To Us | Privacy | Search