... ASP. NET 2.0 pages, ASP. NET 3.0 pages, ASP. NET 3.5 pages, and ASP. NET 4 pages. Each version of .NET Framework is installed in the following folder: C:\WINDOWS\Microsoft .NET\ Framework For example, ... a property named the AssociatedControlID property. You can set this property to point at an ASP. NET control that represents a form field. For example, the page in Listin...
Ngày tải lên: 06/07/2014, 18:20
... using Internet Explorer, you can configure AutoComplete by selecting Tools, Internet Options, Content, and clicking the AutoComplete button. The ASP. NET Framework does not support AutoComplete for ... ptg 75 Accepting User Input 2 For example, the page in Listing 2 .9 sets the focus to the first of two form fields. LISTING 2 .9 TextBoxFocus.aspx <%@ Page Language=”C#” %> <!D...
Ngày tải lên: 06/07/2014, 18:20
ASP.NET 4 Unleased - p 19 pptx
... and Text property is that any message that you assign to the ErrorMessage property appears in the ValidationSummary control, and any message that you assign to the Text property appears in ... property. This property contains the name of a JavaScript function defined in the page’s <head> tag. The JavaScript validation function accepts the same two parameters as the server-side ... /...
Ngày tải lên: 06/07/2014, 18:20
ASP.NET 4 Unleased - p 21 pptx
... Figure 4. 1). 4 FIGURE 4. 1 Displaying a photo gallery. From the Library of Wow! eBook ptg 181 Accepting File Uploads NOTE Adding a FileUpload control to a page automatically adds a enctype=”multipart/form-data” ... control. LISTING 4. 1 FileUploadFile.aspx <%@ Page Language=”C#” %> <%@ Import Namespace=”System.IO” %> <!DOCTYPE html PUBLIC -/ /W3C//DTD XHTML 1.0 Tra...
Ngày tải lên: 06/07/2014, 18:20
ASP.NET 4 Unleased - p 29 pptx
... content=”HtmlMeta,Page.Header ,ASP. NET /> Exposing Master Page Properties You can expose properties and methods from a Master Page and modify the properties and methods from a particular content page. ... custom property in a Master Page, such as the BodyTitle prop- erty, the value of the Master property must be cast to the right type. The BodyTitle property is not a property of the ge...
Ngày tải lên: 06/07/2014, 18:20
ASP.NET 4 Unleased - p 57 pptx
... = upPhoto.FileName; string savePath = MapPath(“~/Photos/” + upPhoto.FileName); // Save contents to file system upPhoto.SaveAs(savePath); } </script> From the Library of Wow! eBook ptg 538 ... void frmPhoto_ItemInserting(object sender, FormViewInsertEventArgs e) { // Get the FileUpload control FileUpload upPhoto = (FileUpload)frmPhoto.FindControl(“upPhoto”); srcImages.InsertParame...
Ngày tải lên: 06/07/2014, 18:20
ASP.NET 4 Unleased - p 66 pptx
... CommandName=”Update” Runat=”server” /> | < ;asp: LinkButton id=”lnkCancel” Text=”Cancel Update” CommandName=”Cancel” Runat=”server” /> </EditItemTemplate> < /asp: FormView> < ;asp: SqlDataSource ... record into the Movies data- base table. LISTING 12.23 ShowFormViewInserting.aspx <%@ Page Language=”C#” %> <!DOCTYPE html PUBLIC -/ /W3C//DTD XHTML 1.1//EN”...
Ngày tải lên: 06/07/2014, 18:20
ASP.NET 4 Unleased - p 70 pptx
... ); photos.Add( “~/Images/Tulips.jpg” ); lstPhotos.DataSource = photos; lstPhotos.DataBind(); } </script> <html xmlns=”http://www.w3.org/ 199 9/xhtml”> FIGURE 14. 3 Displaying a photo ... eBook ptg 667 Using the ListView Control 14 LISTING 14. 3 PhotoGallery.aspx <%@ Page Language=”C#” %> <%@ Import Namespace=”System.Collections.Generic” %> <!DOCTYPE html PUB...
Ngày tải lên: 06/07/2014, 18:20
ASP.NET 4 Unleased - p 87 pptx
... Listing 18 .45 , the PagePropertyParameter represents the current username. Because the PagePropertyParameter can represent any page property, the parameter could represent any type of value. Summary In ... Control Creating a Page Property Parameter PagePropertyParameter enables you to represent an arbitrary property of the current page. The property being represented can return whatever t...
Ngày tải lên: 06/07/2014, 18:20
ASP.NET 4 Unleased - p 92 pptx
... records. LISTING 19. 27 ShowDataAdapterUpdate.aspx <%@ Page Language=”C#” %> <%@ Import Namespace=”System.Data” %> <%@ Import Namespace=”System.Data.SqlClient” %> <%@ Import Namespace=”System.Web.Configuration” ... eBook ptg 885 Connected Data Access 19 LISTING 19. 23 ShowDataLayer1.aspx <%@ Page Language=”C#” %> <%@ Import Namespace=”System.Collections.Gen...
Ngày tải lên: 06/07/2014, 18:20