Beispiel #1
0
        protected void img_ExportToExcel6_Click(object sender, ImageClickEventArgs e)
        {
            if (txt_CodeOstad.Text == string.Empty)
            {
                txt_CodeOstad.Text = "0";
            }
            dtResault = FRB.TeachingExperienceMoreThanADay(ddl_Term.SelectedValue, int.Parse(txt_CodeOstad.Text), int.Parse(ddl_Daneshkade.SelectedValue), int.Parse(ddl_Departman.SelectedValue), int.Parse(ddl_Cooperation.SelectedValue), int.Parse(txt_ListSavabeghRuz.Text));
            if (dtResault.Rows.Count == 0)
            {
            }
            else
            {
                GridView6.DataSource = dtResault;
                GridView6.DataBind();
                Response.Clear();
                Response.Buffer = true;
                Response.AddHeader("content-disposition", "attachment;filename=ReportTeachingExperienceMoreThanADay.xls");
                Response.Charset     = "";
                Response.ContentType = "application/vnd.ms-excel";
                using (StringWriter sw = new StringWriter())
                {
                    HtmlTextWriter hw = new HtmlTextWriter(sw);

                    //To Export all pages
                    ////gv_Show.AllowPaging = false;
                    ////this.BindGrid();

                    //gv_Show.HeaderRow.BackColor = Color.White;
                    foreach (TableCell cell in GridView6.HeaderRow.Cells)
                    {
                        cell.BackColor = GridView6.HeaderStyle.BackColor;
                    }
                    foreach (GridViewRow row in GridView6.Rows)
                    {
                        //row.BackColor = Color.White;
                        foreach (TableCell cell in row.Cells)
                        {
                            if (row.RowIndex % 2 == 0)
                            {
                                cell.BackColor = GridView6.AlternatingRowStyle.BackColor;
                            }
                            else
                            {
                                cell.BackColor = GridView6.RowStyle.BackColor;
                            }
                            cell.CssClass = "textmode";
                        }
                    }

                    GridView6.RenderControl(hw);

                    //style to format numbers to string
                    string style = @"<style> .textmode { } </style>";
                    Response.Write(style);
                    Response.Output.Write(sw.ToString());
                    Response.Flush();
                    Response.End();
                }
            }
        }
Beispiel #2
0
        protected void Button24_Click(object sender, EventArgs e)
        {
            bool load_part1 = false;

            if (TextBox19.Text == "")
            {
                Response.Write("<script language=javascript>alert('資料尚未輸入!')</script>");
            }
            else
            {
                GridView6.Visible = true;
                load_part1        = DAL.DailyMode.Data_Add2(Session["DatabaseName"].ToString(), "施工取樣試驗記錄", TextBox19.Text);
                SqlDataSource7.ConnectionString = Utility.DBconnection.connect_string(Session["DatabaseName"].ToString());
                SqlDataSource7.SelectCommand    = "Select * From Daily_UsualWord where UW_Type='施工取樣試驗記錄'";
                GridView6.DataBind();
                TextBox19.Text = "";
            }
            GridView3.DataBind();
            if (load_part1)
            {
                Response.Write("<script language=javascript>alert('資料新增成功!')</script>");
            }
            else
            {
                Response.Write("<script language=javascript>alert('資料新增失敗!')</script>");
            }
        }
Beispiel #3
0
 protected void Page_Load(object sender, EventArgs e)
 {
     if ((Session["UserName"] == null) || (Session["CompanyName"] == null))
     {
         Response.Redirect("Login.aspx");
     }
     Sql_test1.ConnectionString = Utility.DBconnection.connect_string(Session["DatabaseName"].ToString());
     Sql_test2.ConnectionString = Utility.DBconnection.connect_string(Session["DatabaseName"].ToString());
     Sql_test3.ConnectionString = Utility.DBconnection.connect_string(Session["DatabaseName"].ToString());
     Sql_test4.ConnectionString = Utility.DBconnection.connect_string(Session["DatabaseName"].ToString());
     Sql_test5.ConnectionString = Utility.DBconnection.connect_string(Session["DatabaseName"].ToString());
     Sql_test6.ConnectionString = Utility.DBconnection.connect_string(Session["DatabaseName"].ToString());
     Sql_test7.ConnectionString = Utility.DBconnection.connect_string(Session["DatabaseName"].ToString());
     if (!IsPostBack)
     {
         Unit_DDL.DataSource = Utility.Unitlist.UnitList();
         Unit_DDL.DataBind();
         Unit_DDL1.DataSource = Utility.Unitlist.UnitList();
         Unit_DDL1.DataBind();
         List_Show();
         GridView1.DataBind();
         GridView2.DataBind();
         GridView3.DataBind();
         GridView4.DataBind();
         GridView5.DataBind();
         GridView6.DataBind();
         GridView7.DataBind();
     }
     //Sql_test1.SelectCommand = "SELECT * FROM [UsualWord] WHERE Type = '" + lbl_type1.Text + "' and Content like '%" + TB_UsualWord1.Text + "%' and UnitID is null ORDER BY Sortnumber ASC";
     //Sql_test5.SelectCommand = "SELECT * FROM [UsualWord] WHERE Type = '" + lbl_type2.Text + "' and Content like '%" + TB_UsualWord2.Text + "%' and UnitID is not null ORDER BY Sortnumber ASC";
 }
Beispiel #4
0
 protected void Button26_Click(object sender, EventArgs e)
 {
     GridView6.Visible = true;
     SqlDataSource7.ConnectionString = Utility.DBconnection.connect_string(Session["DatabaseName"].ToString());
     SqlDataSource7.SelectCommand    = "Select * From Daily_UsualWord where UW_Type='施工取樣試驗記錄'";
     GridView6.DataBind();
 }
        protected void Button6_Click(object sender, EventArgs e)
        {
            string        cmd = "exec sp_OtherProductInfo " + TextBox6.Text;
            string        connectionString = ConfigurationManager.ConnectionStrings["conStr"].ToString();
            SqlConnection con = new SqlConnection(connectionString);

            SqlDataAdapter da = new SqlDataAdapter(cmd, con);

            DataSet ds = new DataSet();

            da.Fill(ds);

            try
            {
                con.Open();
            }
            catch (Exception)
            {
                con.Close();
                return;

                throw;
            }


            GridView6.DataSource = ds;
            GridView6.DataBind();
            con.Close();
        }
Beispiel #6
0
    protected void Button2_Click(object sender, EventArgs e)
    {
        if (User.Identity.IsAuthenticated)
        {
            SqlConnection con1000 = new SqlConnection(ConfigurationManager.AppSettings["connection"]);
            SqlCommand    cmd1000 = new SqlCommand("select * from user_details where company_name='" + User.Identity.Name + "'", con1000);
            SqlDataReader dr1000;
            con1000.Open();
            dr1000 = cmd1000.ExecuteReader();
            if (dr1000.Read())
            {
                company_id = Convert.ToInt32(dr1000["com_id"].ToString());

                if (DropDownList1.SelectedItem.Text == "Select customer")
                {
                    ScriptManager.RegisterClientScriptBlock(this, this.GetType(), "alert Message", "alert('Please select customer')", true);
                }
                else
                {
                    SqlConnection  con = new SqlConnection(ConfigurationManager.AppSettings["connection"]);
                    SqlCommand     CMD = new SqlCommand("select * from receive_amount where customer='" + DropDownList1.SelectedItem.Text + "' and  Com_Id='" + company_id + "' order by NO asc", con);
                    DataTable      dt1 = new DataTable();
                    SqlDataAdapter da1 = new SqlDataAdapter(CMD);
                    da1.Fill(dt1);
                    GridView6.DataSource = dt1;
                    GridView6.DataBind();
                }
            }
            con1000.Close();
        }
    }
Beispiel #7
0
        private void BindDataList6()
        {
            if (txtGLNumStart.Text != "" && txtGLNumEnd.Text != " ")
            {
                if (IsValidate(txtGLNumStart.Text) && IsValidate(txtGLNumEnd.Text))
                {
                    QueryParam qp = new QueryParam();
                    qp.PageIndex = AspNetPager2.CurrentPageIndex;
                    qp.PageSize  = AspNetPager2.PageSize;
                    int     RecordCount = 0;
                    DataSet ds          = null;
                    ds = BusinessFacadeDLT.UserGLCount(ddlGLGameID.SelectedValue, txtGLNumStart.Text, txtGLNumEnd.Text, DateTime.Parse(TextBox2.Text), DateTime.Parse(TextBox3.Text), qp.PageIndex, qp.PageSize, ddlOrderType.SelectedValue);

                    GridView6.DataSource = ds.Tables[0];
                    GridView6.DataBind();
                    RecordCount = int.Parse(ds.Tables[1].Rows[0][0].ToString());
                    this.AspNetPager2.RecordCount = RecordCount;
                }
                else
                {
                    Response.Write("<script language='javascript'>alert('下家接单数必须为正整数!');</script>");
                    return;
                }
            }
            else
            {
                Response.Write("<script language='javascript'>alert('下家接单数范围不能为空!');</script>");
                return;
            }
        }
Beispiel #8
0
    protected void Page_Load(object sender, EventArgs e)
    {
        //显示各个论坛分区的帖子列表
        //获取特定组的主题帖
        localhost.Service myBBS        = new localhost.Service();
        DataSet           titleListDS1 = myBBS.GetSortList("站务通知");

        GridView1.DataSource = titleListDS1.Tables["TitleList"].DefaultView;
        GridView1.DataBind();
        DataSet titleListDS2 = myBBS.GetSortList("文化艺术");

        GridView2.DataSource = titleListDS2.Tables["TitleList"].DefaultView;
        GridView2.DataBind();
        DataSet titleListDS3 = myBBS.GetSortList("信息技术");

        GridView3.DataSource = titleListDS3.Tables["TitleList"].DefaultView;
        GridView3.DataBind();
        DataSet titleListDS4 = myBBS.GetSortList("休闲娱乐");

        GridView4.DataSource = titleListDS4.Tables["TitleList"].DefaultView;
        GridView4.DataBind();
        DataSet titleListDS5 = myBBS.GetSortList("学习天地");

        GridView5.DataSource = titleListDS5.Tables["TitleList"].DefaultView;
        GridView5.DataBind();
        //显示投票列表
        DataSet BallotList = myBBS.ShowSubjects();

        GridView6.DataSource = BallotList.Tables["Subject"].DefaultView;
        GridView6.DataBind();
    }
    protected void Button6_Click(object sender, EventArgs e)
    {
        var list = ws1.selectpopcar();

        GridView6.DataSource = list;
        GridView6.DataBind();
    }
Beispiel #10
0
        protected void Button1_Click(object sender, EventArgs e)
        {
            string opis         = dbOpis.Text;
            string nazwaServera = dbServer.Text;
            string nazwabazy    = dbNazwa.Text;
            string user         = dbUser.Text;
            string haslo        = dbPasswd.Text.Trim();
            string ansver       = cl.dodaj_baze_danych(opis, nazwaServera, nazwabazy, user, haslo, DropDownList6.SelectedValue.ToString().Trim());

            try
            {
                int i = int.Parse(ansver);
                if (i == 0)
                {
                    Panel16.Visible = false;
                    Panel14.Visible = true;
                    GridView6.DataBind();
                    Label16.Text = "Dodano pomyślnie bazę danych: " + opis;
                }
            }
            catch
            {
                Label16.Text = "niepowodzenie dodania bazy danych: " + opis + "<br/> Kod błedu: " + ansver;
            }
        }
Beispiel #11
0
 protected void ChooseCra_Click(object sender, EventArgs e)
 {
     Panel5.Visible       = true;
     GridView6.DataSource = dp.Query_PBC("%");
     GridView6.DataBind();
     UpdatePanel5.Update();
 }
Beispiel #12
0
    protected void Buttonlviewtask(object sender, EventArgs e)
    {
        string        connStr = ConfigurationManager.ConnectionStrings["MyDbConn"].ToString();
        SqlConnection conn    = new SqlConnection(connStr);

        conn.Open();
        SqlCommand cmd = new SqlCommand("viewtask", conn);

        cmd.CommandType = CommandType.StoredProcedure;
        cmd.Parameters.Add(new SqlParameter("@regular", Session["Username"].ToString()));
        cmd.Parameters.Add(new SqlParameter("@project_name", TextBox1.Text.ToString()));
        cmd.ExecuteNonQuery();
        GridView1.EmptyDataText = "no tasks";
        SqlDataAdapter adapter = new SqlDataAdapter(cmd);
        DataSet        ds      = new DataSet();

        adapter.Fill(ds);

        if (ds.Tables.Count == 0)
        {
            GridView6.Visible = false;
        }
        else
        {
            GridView6.DataSource = ds;
            GridView6.DataBind();
            GridView6.Visible = true;
        }
        conn.Close();
    }
Beispiel #13
0
    protected void GridView6_PageIndexChanging(object sender, GridViewPageEventArgs e)
    {
        GridView theGrid      = sender as GridView; // refer to the GridView
        int      newPageIndex = 0;

        if (-2 == e.NewPageIndex)
        {
            TextBox     txtNewPageIndex = null;
            GridViewRow pagerRow        = GridView6.BottomPagerRow;


            if (null != pagerRow)
            {
                txtNewPageIndex = (TextBox)pagerRow.FindControl("textbox");   // refer to the TextBox with the NewPageIndex value
            }

            if (null != txtNewPageIndex && txtNewPageIndex.Text != "")
            {
                newPageIndex = int.Parse(txtNewPageIndex.Text) - 1; // get the NewPageIndex
            }
        }
        else
        {
            newPageIndex = e.NewPageIndex;
        }
        GridView6.DataSource = dp.Query_PBC(TextBox18.Text);
        GridView6.DataBind();
        newPageIndex        = newPageIndex < 0 ? 0 : newPageIndex;
        newPageIndex        = newPageIndex >= GridView6.PageCount ? GridView6.PageCount - 1 : newPageIndex;
        GridView6.PageIndex = newPageIndex;
        GridView6.DataBind();
    }
Beispiel #14
0
    //Copy gridview panel to another gridview.
    protected void btnGenerate_Click(object sender, EventArgs e)
    {
        DataTable dt1 = new DataTable();

        dt1.Columns.Add("Memory Block Size [kB]", typeof(string));

        foreach (GridViewRow gvr in GridView6.Rows)
        {
            string var1 = gvr.Cells[0].Text;

            DataRow dr = dt1.NewRow();
            dr["Memory Block Size [kB]"] = var1;

            dt1.Rows.Add(dr);
        }
        GridView3.DataSource = dt1;
        GridView3.DataBind();

        GridView11.DataSource = null;
        GridView6.DataSource  = null;
        GridView6.DataBind();
        GridView11.DataBind();
        DropDownList3.Items.Clear();
        txtMemSize.Text = "";
        TextBox3.Text   = "";
    }
    private void getBuilding(String lid, String trnDate, String amount, String description, String reference, String period, String code, bool alloc, DateTime dt, String oldReference)
    {
        String  sql = "SELECT Building, Code, AccNumber, Contra, DataPath FROM tblBuildings WHERE (Code = '" + code + "') ";
        DataSet ds  = utils.getData(sql, null);

        if (!alloc)
        {
            trnDate = dt.ToString("dd/MM/yyyy");
        }
        if ((ds != null) && (ds.Tables.Count > 0) && (ds.Tables[0].Rows.Count > 0))
        {
            DataRow dr   = ds.Tables[0].Rows[0];
            String  sql2 = "INSERT INTO tblExport (lid, trnDate, amount, building, code, description, reference, accnumber, contra, datapath, period, una)";
            sql2 += " VALUES('" + lid + "', '" + trnDate + "', '" + amount + "', '" + dr["Building"].ToString() + "', '" + code + "', '" + description + "', '" + reference;
            sql2 += "', '" + dr["AccNumber"].ToString() + "', '" + dr["Contra"].ToString() + "', '" + dr["DataPath"].ToString() + "', '" + period + "', '" + alloc.ToString() + "');";

            sql2 += "INSERT INTO tblMatch(statementRef, astroRef) VALUES('" + oldReference + "','" + reference + "')";
            //lblError.Text = sql2;
            String sqlReply = utils.executeQuery(sql2, null);
            if (sqlReply == "")
            {
                SqlDataSource5.Select(new DataSourceSelectArguments());
                SqlDataSource5.DataBind();
                GridView5.DataBind();
                SqlDataSource1.Select(new DataSourceSelectArguments());
                SqlDataSource1.DataBind();
                GridView6.DataBind();
            }
            else
            {
                lblError.Text = sqlReply;
            }
        }
    }
Beispiel #16
0
        private void ShowQ29WeightLW()
        {
            MySqlConnection con = new MySqlConnection(constr);

            try
            {
                con.Open();
                MySqlCommand cmd = new MySqlCommand("select * from weight_lw_crf6 where form_crf_6_id='" + Convert.ToString(Session["form_crf_6_id"]) + "' ", con);
                {
                    MySqlDataAdapter sda = new MySqlDataAdapter();
                    {
                        cmd.Connection    = con;
                        sda.SelectCommand = cmd;
                        DataTable dt = new DataTable();
                        {
                            sda.Fill(dt);
                            GridView6.DataSource = dt;
                            GridView6.DataBind();
                            con.Close();
                        }
                    }
                }
            }
            catch (Exception ex)
            {
                Response.Write("<script type=\"text/javascript\">alert('" + ex.Message + "')</script>");
            }
            finally
            {
                con.Close();
            }
        }
    public void blindtable()
    {
        DataSet ds = new DataSet();

        ds = db.ExecuteDataSet("select * from tbl_demo_paper");
        GridView6.DataSource = ds.Tables[0];
        GridView6.DataBind();
    }
Beispiel #18
0
    protected void SearhCra_Click(object sender, EventArgs e)
    {
        string name = TextBox18.Text;

        GridView6.DataSource = dp.Query_PBC(name);
        GridView6.DataBind();
        UpdatePanel5.Update();
    }
Beispiel #19
0
 //Clear all data in memory panel
 protected void ButtonClear_Click(object sender, EventArgs e)
 {
     TextBox3.Text   = " ";
     txtMemSize.Text = " ";
     DropDownList3.Items.Clear();
     GridView6.DataSource = null;
     GridView6.DataBind();
 }
 protected void GridView6_PageIndexChanging(object sender, GridViewPageEventArgs e)
 {
     GridView6.PageIndex  = e.NewPageIndex;
     GridView6.DataSource = RFID;
     GridView6.DataBind();
     ChartMode();
     UpdatePanel6.Update();
 }
Beispiel #21
0
 protected void GridView6_RowCommand(object sender, GridViewCommandEventArgs e)
 {
     if (e.CommandName == "Insert")
     {
         GridView6.DataSourceID = "";
     }
     GridView6.DataBind();
 }
Beispiel #22
0
    protected void GridView1_RowCommand(object sender, GridViewCommandEventArgs e)
    {
        GridViewRow row = ((LinkButton)e.CommandSource).Parent.Parent as GridViewRow;

        if (e.CommandName == "Return")
        {
            Panel5.Visible       = true;
            CopperID.Text        = e.CommandArgument.ToString();
            GridView3.DataSource = pmc.Query_CopperReturn(new Guid(CopperID.Text));
            GridView3.DataBind();

            Debug.Assert(row != null, "Oh My LadyGaga!");
            Label16.Text = row.Cells[2].Text;

            Label20.Text = row.Cells[10].Text;

            UpdatePanel5.Update();
        }
        if (e.CommandName == "NG")
        {
            Panel7.Visible = true;

            CopperID.Text        = e.CommandArgument.ToString();
            GridView4.DataSource = pmc.Query_CopperNG(new Guid(CopperID.Text));
            GridView4.DataBind();
            Label15.Text = row.Cells[2].Text;
            Label17.Text = row.Cells[10].Text;
            UpdatePanel7.Update();
        }
        if (e.CommandName == "Modi")
        {
            CopperID.Text = e.CommandArgument.ToString();

            Label4.Text        = "修改";
            LabelUsage.Visible = true;
            TextBox47.Visible  = true;
            TextBox47.Text     = row.Cells[12].Text;
            Panel3.Visible     = true;
            UpdatePanel3.Update();
            Type.Text         = row.Cells[3].Text;
            Mid.Text          = row.Cells[11].Text;
            TextBox3.Text     = row.Cells[5].Text;
            TextBox6.Text     = row.Cells[4].Text;
            TextBox46.Text    = row.Cells[9].Text;
            ProviderName.Text = row.Cells[2].Text;
            ProviderID.Text   = row.Cells[10].Text;
            CopperRate.Text   = row.Cells[12].Text;
        }
        if (e.CommandName == "OEM")
        {
            Panel10.Visible = true;

            CopperID.Text        = e.CommandArgument.ToString();
            GridView6.DataSource = pmc.Query_CopperOEM(new Guid(CopperID.Text));
            GridView6.DataBind();
            UpdatePanel10.Update();
        }
    }
 protected void DropDownList7_SelectedIndexChanged(object sender, EventArgs e)
 {
     if (DropDownList7.SelectedIndex == 0)
     {
         GridView6.DataSource = "";
         GridView6.DataBind();
         Label6.Text = "";
     }
 }
Beispiel #24
0
 protected void btnDastoorInsert_Click(object sender, EventArgs e)
 {
     if (txtDastoorTitle.Text != "")
     {
         Value.InsertValues(lblDastoorID.Text, lblDastoorValue.Text, txtDastoorTitle.Text);
     }
     txtDastoorTitle.Text = "";
     GridView6.DataBind();
 }
Beispiel #25
0
    protected void freshgrade()
    {
        DataSet        dst  = new DataSet();
        SqlConnection  cnn  = new SqlConnection(System.Configuration.ConfigurationManager.ConnectionStrings["dtcnn"].ConnectionString);
        SqlDataAdapter adpt = new SqlDataAdapter("select * from journal_grade", cnn);

        adpt.Fill(dst);
        GridView6.DataSource = dst.Tables[0];
        GridView6.DataBind();
    }
Beispiel #26
0
        protected void odswiez()
        {
            string yyx = (string)Session["id_dzialu"];

            id_dzialu.Text = (string)Session["txt_dzialu"];
            string txt = string.Empty; //

            cl.deleteRowTable();

            txt = txt + cl.clear_maim_db();
            try
            {
                txt = txt + cl.generuj_dane_do_tabeli_wierszy(Date1.Date, Date2.Date, yyx, 1, tenPlik);
                txt = txt + cl.generuj_dane_do_tabeli_wierszy(Date1.Date, Date2.Date, yyx, 6, tenPlik);
                tabela_02();
                tabela_03();
                tabela_04();
                tabela_05();
                tabela_07();

                /*
                 * txt = txt + cl.generuj_dane_do_tabeli_(int.Parse((string)Session["id_dzialu"]), 2, Date1.Date, Date2.Date);
                 * txt = txt + cl.generuj_dane_do_tabeli_(int.Parse((string)Session["id_dzialu"]), 3, Date1.Date, Date2.Date);
                 * txt = txt + cl.generuj_dane_do_tabeli_(int.Parse((string)Session["id_dzialu"]), 4, Date1.Date, Date2.Date);
                 * txt = txt + cl.generuj_dane_do_tabeli_(int.Parse((string)Session["id_dzialu"]), 5, Date1.Date, Date2.Date);
                 * txt = txt + cl.generuj_dane_do_tabeli_(int.Parse((string)Session["id_dzialu"]), 6, Date1.Date, Date2.Date);
                 * txt = txt + cl.generuj_dane_do_tabeli_(int.Parse((string)Session["id_dzialu"]), 7, Date1.Date, Date2.Date);*/
            }
            catch
            {
            }

            // dopasowanie opisów
            makeLabels();
            GridView1.DataBind();
            GridView2.DataBind();
            GridView3.DataBind();
            GridView4.DataBind();
            GridView6.DataBind();
            GridView7.DataBind();
            GridView8.DataBind();

            try
            {
                Label11.Visible = cl.debug(int.Parse(yyx));
            }
            catch
            {
                Label11.Visible = false;
            }

            Label11.Text = txt;
            Label3.Text  = cl.nazwaSadu((string)Session["id_dzialu"]);
        }
        protected void Button6_Click(object sender, EventArgs e)
        {
            String         query       = "SELECT a.Product_id , a.Product_name, b.Product_item_no, b.Product_size, b.Product_cost , c.Order_cost FROM Product a , Size_cost b , Order_table c WHERE (c.Product_item_no = b.Product_item_no AND b.Product_id = a.Product_id AND c.Customer_id = '" + TextBox8.Text + "')";
            SqlDataAdapter dataadapter = new SqlDataAdapter(query, conx);
            DataSet        ds          = new DataSet();

            dataadapter.Fill(ds);

            GridView6.DataSource = ds;
            GridView6.DataBind();
        }
 // Updates the grid veiw after adding the new data
 protected void UpdateTablesData()
 {
     GridView1.DataBind();
     GridView2.DataBind();
     GridView3.DataBind();
     GridView4.DataBind();
     GridView5.DataBind();
     GridView6.DataBind();
     GridView7.DataBind();
     GridView8.DataBind();
 }
Beispiel #29
0
 void ShowData3()
 {
     using (SqlConnection cn = new SqlConnection())
     {
         SqlConnection conn = new SqlConnection(strConn);
         conn.Open();
         SqlCommand    cmd = new SqlCommand("SELECT *  FROM  员工", conn);
         SqlDataReader dr  = cmd.ExecuteReader();
         GridView6.DataSource = dr;
         GridView6.DataBind();
     }
 }
Beispiel #30
0
        protected void LinkButton13_Click(object sender, EventArgs e)
        {
            try
            {
                cl.update_bazy_danych(TextBox9.Text.Trim(), TextBox10.Text.Trim(), TextBox11.Text.Trim(), TextBox12.Text.Trim(), TextBox13.Text.Trim(), DropDownList4.SelectedValue.ToString().Trim(), (string)Session["id_bazy"]);

                GridView6.DataBind();
            }
            catch
            {
            }
        }