Beispiel #1
0
 protected void TextBox11_TextChanged(object sender, EventArgs e)
 {
     Warehouse.Controllor.JudgeChinese ju = new Controllor.JudgeChinese();
     DAL.sameQuary sq = new DAL.sameQuary();
     if (ju.Judge(TextBox11.Text))
     {
         bool xx = sq.quary("Chest", "chestName", TextBox11.Text);
         if (xx)
         {
             Image2.ImageUrl = "~/Image/对号.png";
             Image2.Visible  = true;
             Label3.Visible  = false;
         }
         else
         {
             Image2.ImageUrl = "~/Image/错号.png";
             Image2.Visible  = true;
             Label3.Visible  = true;
             Label3.Text     = "已存在该库柜名,请重新输入";
             TextBox11.Text  = "";
         }
     }
     else
     {
         Image2.ImageUrl = "~/Image/错号.png";
         Image2.Visible  = true;
         Label3.Visible  = true;
         Label3.Text     = "您的库柜名称输入不合理,请重新输入";
     }
 }
 protected void TextBox11_TextChanged(object sender, EventArgs e)
 {
     Warehouse.Controllor.JudgeChinese ju = new Controllor.JudgeChinese();
     DAL.sameQuary sq = new DAL.sameQuary();
     if (ju.Judge(TextBox11.Text))
     {
         bool xx = sq.quary("Positiontype", "positionTypeName", TextBox11.Text);
         if (xx)
         {
             Image2.ImageUrl = "~/Image/对号.png";
             Image2.Visible  = true;
             Label3.Visible  = false;
         }
         else
         {
             Image2.ImageUrl = "~/Image/错号.png";
             Image2.Visible  = true;
             Label3.Visible  = true;
             Label3.Text     = "已存在该类型,请重新输入";
             TextBox11.Text  = "";
         }
     }
     else
     {
         Image2.ImageUrl = "~/Image/错号.png";
         Image2.Visible  = true;
         Label3.Visible  = true;
         Label3.Text     = "您的房间名称只能含有汉字";
     }
 }
Beispiel #3
0
 protected void TextBox11_TextChanged(object sender, EventArgs e)
 {
     Warehouse.Controllor.JudgeChinese ju = new Controllor.JudgeChinese();
     DAL.sameQuary sq = new DAL.sameQuary();
     if (ju.Judge(TextBox11.Text))
     {
         bool xx = sq.quary("Goodstype", "goodsTypeName", TextBox11.Text);
         if (xx)
         {
             Image2.ImageUrl = "~/Image/对号.png";
             Image2.Visible  = true;
             Label1.Visible  = false;
         }
         else
         {
             Image2.ImageUrl = "~/Image/错号.png";
             Image2.Visible  = true;
             Label1.Visible  = true;
             Label1.Text     = "已存在该物品名,请重输";
             TextBox11.Text  = "";
             this.TextBox11.Focus();
         }
     }
     else
     {
         Image2.ImageUrl = "~/Image/错号.png";
         Image2.Visible  = true;
         Label1.Visible  = true;
         Label1.Text     = "名称输入不合理,请重新输入";
         this.TextBox11.Focus();
         TextBox11.Text = "";
     }
 }
Beispiel #4
0
 protected void TextBox6_TextChanged(object sender, EventArgs e)
 {
     if (TextBox6.Text == "")
     {
         Image8.Visible  = true;
         Image8.ImageUrl = "~/Image/错号.png";
         ClientScript.RegisterClientScriptBlock(this.GetType(), "msg", "alert('不能为空!');", true);
     }
     else
     {
         Warehouse.Controllor.JudgeChinese ju = new Controllor.JudgeChinese();
         if (ju.Judge(TextBox6.Text))
         {
             Image8.Visible  = true;
             Image8.ImageUrl = "~/Image/对号.png";
         }
         else
         {
             Image8.Visible  = true;
             Image8.ImageUrl = "~/Image/错号.png";
             ClientScript.RegisterClientScriptBlock(this.GetType(), "msg", "alert('请重新输入,只能输入汉字!');", true);
         }
     }
 }