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

📄 selectclass.aspx

📁 智能选课系统:本程序采用Microsoft Visual Studio 2005集成环境开发即 asp.net 2.0+access 数据库开发。 功能如下:学校中学生教师根据不同的权限合理分配,提
💻 ASPX
字号:
<%@ Page Language="C#" MasterPageFile="~/student/Student.master" AutoEventWireup="true" CodeFile="SelectClass.aspx.cs" Inherits="studnet_SelectClass" Title="Untitled Page" %>
<asp:Content ID="Content1" ContentPlaceHolderID="ContentPlaceHolder1" Runat="Server">
    <table border="0" cellpadding="0" cellspacing="0" style="border-right: #66ccff 0.1mm solid;
        border-top: #66ccff 0.1mm solid; border-left: #66ccff 0.1mm solid; border-bottom: #66ccff 0.1mm solid; width: 100%;">
        <tr>
            <td align="center" colspan="3" style="width: 549px; border-bottom: #66ccff 0.1mm solid;
                height: 17px">
                选课系统</td>
        </tr>
        <tr>
            <td colspan="3" rowspan="5" style="width: 549px;" valign="top">
                选择专业:<asp:DropDownList ID="DropDownList2" runat="server" AutoPostBack="True" DataSourceID="AccessDataSource2"
                    DataTextField="zhuanyename" DataValueField="zhuanyename" Width="103px">
                </asp:DropDownList></td>
        </tr>
        <tr>
        </tr>
        <tr>
        </tr>
        <tr>
        </tr>
        <tr>
        </tr> <tr>
            <td align="center" colspan="3" style="width: 549px; height: 19px">
                以下为必修课:</td>
        </tr> <tr>
            <td align="center" colspan="3" style="width: 549px; height: 133px" valign="top">
                <asp:GridView ID="GridView1" runat="server" AutoGenerateColumns="False" CellPadding="4"
                    DataKeyNames="Classid" DataSourceID="AccessDataSource1" ForeColor="#333333" GridLines="None"
                    Width="100%">
                    <FooterStyle BackColor="#5D7B9D" Font-Bold="True" ForeColor="White" />
                    <Columns>
                        <asp:BoundField DataField="Classid" HeaderText="编号" InsertVisible="False" ReadOnly="True"
                            SortExpression="Classid" />
                        <asp:BoundField DataField="CClass" HeaderText="系" SortExpression="CClass" />
                        <asp:BoundField DataField="Czhuanye" HeaderText="专业" SortExpression="Czhuanye" />
                        <asp:BoundField DataField="Cname" HeaderText="课程名称" SortExpression="Cname" />
                        <asp:BoundField DataField="Cteacher" HeaderText="教师" SortExpression="Cteacher" />
                        <asp:BoundField DataField="CweekBegTime" HeaderText="开始周" SortExpression="CweekBegTime" />
                        <asp:BoundField DataField="CweekEndTime" HeaderText="结束周" SortExpression="CweekEndTime" />
                        <asp:BoundField DataField="Cdate" HeaderText="星期" SortExpression="Cdate" />
                        <asp:BoundField DataField="Ctime" HeaderText="节次" SortExpression="Ctime" />
                    </Columns>
                    <RowStyle BackColor="#F7F6F3" ForeColor="#333333" />
                    <EditRowStyle BackColor="#999999" />
                    <SelectedRowStyle BackColor="#E2DED6" Font-Bold="True" ForeColor="#333333" />
                    <PagerStyle BackColor="#284775" ForeColor="White" HorizontalAlign="Center" />
                    <HeaderStyle BackColor="#5D7B9D" Font-Bold="True" ForeColor="White" />
                    <AlternatingRowStyle BackColor="White" ForeColor="#284775" />
                </asp:GridView>
                &nbsp; &nbsp;
                &nbsp; &nbsp;</td>
        </tr> <tr>
            <td align="left" colspan="3" style="width: 549px; height: 19px">
                选择选修课:&nbsp;
            </td>
        </tr> <tr>
            <td align="center" colspan="3" style="width: 549px; height: 125px" valign="top">
                <asp:GridView ID="GridView2" runat="server" AutoGenerateColumns="False" CellPadding="4"
                    DataKeyNames="Classid" DataSourceID="AccessDataSource4" ForeColor="#333333" GridLines="None"
                    Width="106%" OnSelectedIndexChanged="GridView2_SelectedIndexChanged">
                    <FooterStyle BackColor="#5D7B9D" Font-Bold="True" ForeColor="White" />
                    <Columns>
                        <asp:CommandField ShowSelectButton="True" />
                        <asp:BoundField DataField="CClass" HeaderText="系" SortExpression="CClass" />
                        <asp:BoundField DataField="Czhuanye" HeaderText="专业" SortExpression="Czhuanye" />
                        <asp:BoundField DataField="Cname" HeaderText="名称" SortExpression="Cname" />
                        <asp:BoundField DataField="Cteacher" HeaderText="教师" SortExpression="Cteacher" />
                        <asp:BoundField DataField="CweekBegTime" HeaderText="开始周" SortExpression="CweekBegTime" />
                        <asp:BoundField DataField="CweekEndTime" HeaderText="结束周" SortExpression="CweekEndTime" />
                        <asp:BoundField DataField="Cdate" HeaderText="星期" SortExpression="Cdate" />
                        <asp:BoundField DataField="Ctime" HeaderText="节次" SortExpression="Ctime" />
                    </Columns>
                    <RowStyle BackColor="#F7F6F3" ForeColor="#333333" />
                    <EditRowStyle BackColor="#999999" />
                    <SelectedRowStyle BackColor="#E2DED6" Font-Bold="True" ForeColor="#333333" />
                    <PagerStyle BackColor="#284775" ForeColor="White" HorizontalAlign="Center" />
                    <HeaderStyle BackColor="#5D7B9D" Font-Bold="True" ForeColor="White" />
                    <AlternatingRowStyle BackColor="White" ForeColor="#284775" />
                </asp:GridView>
                &nbsp; &nbsp;
                &nbsp; &nbsp;</td>
        </tr> <tr>
            <td align="left" colspan="3" style="width: 549px; height: 19px">
                你选择的课程详细信息如下:</td>
               
        </tr><tr>
            <td align="left" colspan="3" style="width: 549px; height: 19px">
                课程名称:
                <asp:TextBox ID="txtname" runat="server"></asp:TextBox></td>
               
        </tr> <tr>
            <td align="left" colspan="3" style="width: 549px; height: 19px">
                系别: &nbsp; &nbsp; &nbsp;&nbsp;
                <asp:TextBox ID="txtxi" runat="server"></asp:TextBox></td>
               
        </tr> <tr>
            <td align="left" colspan="3" style="width: 549px; height: 19px">
                专业: &nbsp; &nbsp; &nbsp; &nbsp;<asp:TextBox ID="txtzhuanye" runat="server"></asp:TextBox></td>
               
        </tr> <tr>
            <td align="left" colspan="3" style="width: 549px; height: 19px">
                开始周: &nbsp;&nbsp;
                <asp:TextBox ID="txtkaishi" runat="server"></asp:TextBox></td>
               
        </tr> <tr>
            <td align="left" colspan="3" style="width: 549px; height: 19px">
                结束周: &nbsp; &nbsp;<asp:TextBox ID="txtjieshu" runat="server"></asp:TextBox></td>
               
        </tr> <tr>
            <td align="left" colspan="3" style="width: 549px; height: 19px">
                星期: &nbsp; &nbsp; &nbsp; &nbsp;<asp:TextBox ID="txtweek" runat="server"></asp:TextBox></td>
               
        </tr> <tr>
            <td align="left" colspan="3" style="width: 549px; height: 19px">
                节次: &nbsp; &nbsp; &nbsp; &nbsp;<asp:TextBox ID="txtjieci" runat="server"></asp:TextBox></td>
               
        </tr> <tr>
            <td align="left" colspan="3" style="width: 549px; height: 19px">
                任课教师:
                <asp:TextBox ID="txtlaoshi" runat="server"></asp:TextBox></td>
               
        </tr> 
        
         <tr>
            <td align="center" colspan="3" style="width: 549px; height: 19px">
                &nbsp;<asp:LinkButton ID="Linkadd" runat="server" OnClick="Linkadd_Click" Width="97px">确定</asp:LinkButton></td>
        </tr> 
    </table>
    &nbsp;
    <asp:AccessDataSource ID="AccessDataSource2" runat="server" DataFile="~/database/xuanke.mdb"
        SelectCommand="SELECT * FROM [zhuanye]"></asp:AccessDataSource>
                <asp:AccessDataSource ID="AccessDataSource4" runat="server" DataFile="~/database/xuanke.mdb"
                    SelectCommand="SELECT * FROM [JiaoyanshiClass] WHERE (([Cshifouxuanxiu] = ?) AND ([Cshencha] = ?))">
                    <SelectParameters>
                        <asp:Parameter DefaultValue="是" Name="Cshifouxuanxiu" Type="String" />
                        <asp:Parameter DefaultValue="是" Name="Cshencha" Type="String" />
                    </SelectParameters>
                </asp:AccessDataSource>
    <asp:AccessDataSource ID="AccessDataSource3" runat="server" DataFile="~/database/xuanke.mdb"
        SelectCommand="SELECT * FROM [JiaoyanshiClass] WHERE ([Cshifouxuanxiu] = ?)">
        <SelectParameters>
            <asp:Parameter DefaultValue="是" Name="Cshifouxuanxiu" Type="String" />
        </SelectParameters>
    </asp:AccessDataSource>
                <asp:AccessDataSource ID="AccessDataSource1" runat="server" DataFile="~/database/xuanke.mdb"
                    SelectCommand="SELECT * FROM [JiaoyanshiClass] WHERE (([Czhuanye] = ?) AND ([Cshifouxuanxiu] = ?) AND ([Cshencha] = ?))">
                    <SelectParameters>
                        <asp:ControlParameter ControlID="DropDownList2" Name="Czhuanye" PropertyName="SelectedValue"
                            Type="String" />
                        <asp:Parameter DefaultValue="否" Name="Cshifouxuanxiu" Type="String" />
                        <asp:Parameter DefaultValue="是" Name="Cshencha" Type="String" />
                    </SelectParameters>
                </asp:AccessDataSource>
</asp:Content>

⌨️ 快捷键说明

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