<%@ Page Title="" Language="C#" MasterPageFile="~/MasterPage.master" AutoEventWireup="true" CodeFile="ShowAllCars.aspx.cs" Inherits="ShowAllCars" %>

<asp:Content ID="Content1" ContentPlaceHolderID="head" Runat="Server">
</asp:Content>
<asp:Content ID="Content2" ContentPlaceHolderID="ContentPlaceHolder1" Runat="Server">
    <table style="width:100%;" dir="rtl">
        <tr>
            <td>
                <asp:GridView ID="Grd_AllCar" runat="server" AutoGenerateColumns="False" 
                    DataSourceID="LinqDtCars" Width="100%">
                    <Columns>
                        <asp:BoundField DataField="CarID" HeaderText="CarID" SortExpression="CarID" 
                            Visible="False" />
                        <asp:BoundField DataField="CarName" HeaderText="نام خودرو" 
                            SortExpression="CarName" />
                        <asp:BoundField DataField="PelakNumber" HeaderText="شماره پلاک" 
                            SortExpression="PelakNumber" />
                        <asp:BoundField DataField="ShasiNumber" HeaderText="شماره شاسی" 
                            SortExpression="ShasiNumber" />
                        <asp:BoundField DataField="MotorNumber" HeaderText="شماره موتور" 
                            SortExpression="MotorNumber" />
                        <asp:BoundField DataField="DriverUserName" HeaderText="DriverUserName" 
                            SortExpression="DriverUserName" Visible="False" />
                        <asp:BoundField DataField="CarModel" HeaderText="مدل" 
                            SortExpression="CarModel" />
                        <asp:BoundField DataField="Expr2" HeaderText="مشخصات دارنده خودرو" 
                            SortExpression="Expr2" />
                    </Columns>
                </asp:GridView>
                <asp:LinqDataSource ID="LinqDtCars" runat="server" 
                    ContextTypeName="LSCTamiratDataContext" EnableDelete="True" EnableInsert="True" 
                    EnableUpdate="True" EntityTypeName="" 
                    OrderBy="CarID desc, CarName desc, PelakNumber" TableName="xtblCarDrivers">
                </asp:LinqDataSource>
            </td>
        </tr>
    </table>
</asp:Content>

