ASP.NET Programming Examples

29 downloads 2833 Views 90KB Size Report
ASP.NET. Dr.Qadri Hamarsheh. ASP.NET Mobile Programming. Page 1 of 11. 1. Advanced Programming Language (630501). Fall 2011/2012 – Lectures Notes ...
ASP.NET

Dr.Qadri Hamarsheh ASP.NET Mobile Programming Advanced Programming Language (630501) Fall 2011/2012 – Lectures Notes # 20

ASP.NET Programming Examples Outline of the Lecture    

Example 20-1 Example 20-2 Example 20-3 Example 20-4

Example 2020-1 (Design) ="http://schemas.microsoft.com/Mobile/Page"> mobile="http://schemas.microsoft.com/Mobile/WebForm"> runat="server">

runat="server"> Select the companies Item> Item> Page 1 of 11

1

ASP.NET

Dr.Qadri Hamarsheh ASP.NET Mobile Programming

Item> Item> Item>

CommandLabel ="server">Label Go Back 0) { Label2.Text = str; } else { Label2.Text = "Nothing is selected"; selected"; } this.ActiveForm this.ActiveForm = Form2; } private void Command1_ItemCommand(object Command1_ItemCommand(object sender, System.Web.UI.WebControls.CommandEventArgs e) { } } }

Example 20 20-2 (Design) -1) { // To show the selection, get the Selection property. Label1.Text = "You have selected " + SelectionList1.Selection.Text; SelectionList1.Selection.Text; // This is an alternate means of showing the selection // using the MobileListItemCollection object. Label2.Text = "You have selected " + SelectionList1.Items[SelectionList1.SelectedIndex].Text; } else { Label1.Text = "No items selected"; selected"; } } runat="server">