Monday, September 21, 2009

Chapter 3-Lesson 2

  • We may use Hyperlink control to enable Client-side Navigation within the page. No data is posted to the newly requested page, so we may need to use QueryStrings.
  • Page.PostBackUrl property is used for Cross-page Posting.
  • When a cross-page post is made, data from first page is posted to the second page. The second page may access that data using Page.PreviousPage property.
  • We may use properties to encapsulate controls on a page so that they could be accessed from another page as strongly typed values during a cross-page posting.
  • To access such porperties in the posted page, add PreviousPageType directive after the Page directive and set its VirtualPath attribute. (Page 169 for exact usage)
  • Response.Redirect( ) method is used to cause a Client-side Browser redirect. This is similar to using Hyperlinks as the browser is sent an HTTP 302 message with the URL to redirect.
  • Server.Transfer( ) method is used to cause a Server-side Page Redirection. PreviousPage property is populated for the new page in this case.
  • Sitemap class is used to access Web.sitemap (or other such) files from code. It has three properties namely Title, Url and Description.
  • Menu, TreeView and SiteMapPath are three navigational controls that use Sitemap files.
  • SitemapPath connects itself to the Sitemap file automatically. It can be put on a masterpage where it could check (automatically) current page on which it is displayed and show its bread-crumb trail.

No comments:

Post a Comment