Backup/排课系统/admin/coursetaskadd.aspx.cs
(开头部分) 6KB这里只显示每个文件的开头 60 行。登录后可以解锁完整代码。
using System;
using System.Collections.Generic;
using System.Linq;
using System.Web;
using System.Web.UI;
using System.Web.UI.WebControls;
using System.Text.RegularExpressions;
using System.Data;
namespace 排课系统.admin
{
public partial class coursetaskadd : System.Web.UI.Page
{
protected void Page_Load(object sender, EventArgs e)
{
if (!IsPostBack)
{
if (Session["username"] == null)
{
WebMessageBox.Show("请登录","../Default.aspx");
}
Label1.Text = Session["username"].ToString();
DropDownList1.DataSource = Operation.getDatatable("select name from t_major");//设置数据源
DropDownList1.DataTextField = "name";//设置所要读取的数据表里的列名
DropDownList1.DataBind();//数据绑定
DropDownList2.Items.Add("2010");
DropDownList2.Items.Add("2011");
DropDownList2.Items.Add("2012");
DropDownList2.Items.Add("2013");
DropDownList2.Items.Add("2014");
DropDownList2.Items.Add("2015");
DropDownList2.Items.Add("2016");
DropDownList3.Items.Add("否"); DropDownList3.Items.Add("是");
DropDownList4.Items.Add("否"); DropDownList4.Items.Add("是");
}
}
protected void Button1_Click(object sender, EventArgs e)
{
if (DropDownList1.SelectedIndex < 0)
{
WebMessageBox.Show("请选择专业"); return;
}
if (DropDownList2.SelectedIndex < 0)
{
WebMessageBox.Show("请选择年级"); return;
}
//添加
if (TextBox1.Text == "")
{
WebMessageBox.Show("请输入课程名称"); return;
}
if (TextBox2.Text == "")
{
WebMessageBox.Show("请输入课程性质"); return;
}
if (TextBox3.Text == "")
{
WebMessageBox.Show("请输入考核方式"); return;
}
float xf;
后面还有 89 行代码,解锁后查看完整代码
24 小时内免费解锁 3 个项目,之后 1 积分/个。 规则说明
AI 解读
登录后可用,每次 10 积分,解读结果公开显示在下面。
还没有人解读过这个文件。
