⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 linkedgridviewbe.aspx

📁 wrox出版社的另一套经典的VB2005数据库编程学习书籍,收集了书中源码,郑重推荐,电子书,电子书下载
💻 ASPX
字号:
<%@ Page Language="VB" AutoEventWireup="false" CodeFile="LinkedGridViewBE.aspx.vb" Inherits="LinkedGridViewBE_aspx" EnableSessionState="True" Trace="True" TraceMode="SortByTime" %>

<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.1//EN" "http://www.w3.org/TR/xhtml11/DTD/xhtml11.dtd">

<html xmlns="http://www.w3.org/1999/xhtml" >
<head runat="server">
    <title>ASP.NET 2.0 ObjectDataSources from Business Entity (Untyped DataSet, Read-Only)</title>
</head>
<body style="font-size: 12pt" bottommargin="10" topmargin="10">
  <form id="frmLinked" runat="server">
    <div style="background-color: Gainsboro">
		 <div style="text-align: left">
 		 	<span style="font-size: 14pt; font-family: Arial"><b> &nbsp;Linked GridView Control
			  (ODS - Business Entity)
			</b></span>
			 <table style="width: 665px; height: 419px" cellpadding="2" border="0">
				 <tr>
					 <td style=" height: 209px; background-color: gainsboro" colspan="2">
						 <asp:GridView ID="gvOrders" Runat="server" Font-Size="10pt" PageSize="15" BorderColor="#999999"
							 BorderStyle="None" CellPadding="3" GridLines="Vertical" BackColor="White" BorderWidth="1px"
							 AllowPaging="True" AutoGenerateColumns="False" DataKeyNames="OrderID" DataSourceID="odsOrders"
							 Font-Names="Verdana">
							 <FooterStyle ForeColor="Black" BackColor="#CCCCCC"></FooterStyle>
							 <PagerStyle ForeColor="Black" HorizontalAlign="Left" BackColor="Gainsboro" Font-Names="Arial" Font-Size="12pt" Font-Bold="True"></PagerStyle>
							 <HeaderStyle ForeColor="White" Font-Bold="True" BackColor="#000084"></HeaderStyle>
							 <PagerSettings FirstPageText="First" Mode="NumericFirstLast" LastPageText="Last"></PagerSettings>
							 <AlternatingRowStyle BackColor="Gainsboro"></AlternatingRowStyle>
							 <Columns>
								 <asp:HyperLinkField Text="Select" DataNavigateUrlFields="OrderID" DataNavigateUrlFormatString="LinkedDetailsViewBE.aspx?orderid={0}"></asp:HyperLinkField>
								 <asp:BoundField ReadOnly="True" HeaderText="Order ID" InsertVisible="False" DataField="OrderID"
									 SortExpression="OrderID">
									 <ItemStyle HorizontalAlign="Right"></ItemStyle>
								 </asp:BoundField>
								 <asp:BoundField HeaderText="Cust. ID" DataField="CustomerID" SortExpression="CustomerID"></asp:BoundField>
								 <asp:BoundField HeaderText="Empl. ID" DataField="EmployeeID" SortExpression="EmployeeID">
									 <ItemStyle HorizontalAlign="Center"></ItemStyle>
								 </asp:BoundField>
								 <asp:BoundField HeaderText="Order Date" DataField="OrderDate" DataFormatString="{0:d}">
									 <ItemStyle HorizontalAlign="Right"></ItemStyle>
								 </asp:BoundField>
								 <asp:BoundField HeaderText="Required Date" DataField="RequiredDate" DataFormatString="{0:d}">
									 <ItemStyle HorizontalAlign="Right"></ItemStyle>
								 </asp:BoundField>
								 <asp:BoundField HeaderText="Shipped Date" DataField="ShippedDate" SortExpression="ShippedDate" NullDisplayText="Pending" DataFormatString="{0:d}">
									 <ItemStyle HorizontalAlign="Right"></ItemStyle>
								 </asp:BoundField>
								 <asp:BoundField HeaderText="Ship Via" DataField="ShipVia" SortExpression="ShipVia">
									 <ItemStyle HorizontalAlign="Center"></ItemStyle>
								 </asp:BoundField>
								 <asp:BoundField HeaderText="Freight" DataField="Freight" DataFormatString="{0:c}">
									 <ItemStyle HorizontalAlign="Right"></ItemStyle>
								 </asp:BoundField>
								 <asp:BoundField HeaderText="Ship Name" DataField="ShipName">
									 <ItemStyle Wrap="False"></ItemStyle>
								 </asp:BoundField>
							 </Columns>
							 <SelectedRowStyle ForeColor="White" Font-Bold="True" BackColor="SteelBlue"></SelectedRowStyle>
							 <RowStyle ForeColor="Black" BackColor="#EEEEEE"></RowStyle>
						 </asp:GridView>&nbsp;&nbsp;
						 <asp:ObjectDataSource ID="odsOrders" Runat="server" TypeName="OrdersBE"
							 SelectMethod="GetAllOrders">
						 </asp:ObjectDataSource>
					 </td>
				 </tr>
			 </table>
		 </div>
    </div>
    </form>
  </body>
</html>

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -