Set









How do I use Set
Below are practical examples compiled from projects for learning and reference purposes

Featured Snippets


File name: ClassBLL.cs Copy
307         public void Update(string table, string sql)
308         {
309             sql = "update "+table+" set "+sql+"";
310             da.ExcuteNonQuery(sql);
311         }
File name: crBaoCao.cs Copy
24         public override string ResourceName {
25             get {
26                 return "crBaoCao.rpt";
27             }
28             set {
29                 // Do nothing
30             }
31         }
File name: crBaoCao.cs Copy
33         public override bool NewGenerator {
34             get {
35                 return true;
36             }
37             set {
38                 // Do nothing
39             }
40         }
File name: crBaoCao.cs Copy
42         public override string FullResourceName {
43             get {
44                 return "QuanLyDiem.crBaoCao.rpt";
45             }
46             set {
47                 // Do nothing
48             }
49         }
File name: crBaoCao.cs Copy
108         public virtual bool IsCacheable {
109             get {
110                 return true;
111             }
112             set {
113                 //
114             }
115         }
File name: crBaoCao.cs Copy
119         public virtual bool ShareDBLogonInfo {
120             get {
121                 return false;
122             }
123             set {
124                 //
125             }
126         }
File name: crBaoCao.cs Copy
130         public virtual System.TimeSpan CacheTimeOut {
131             get {
132                 return CachedReportConstants.DEFAULT_TIMEOUT;
133             }
134             set {
135                 //
136             }
137         }
File name: FormBaoCao.cs Copy
40         private void btnLoc_Click(object sender, EventArgs e)
41         {
42             SqlConnection con = dal.GetConnect();
43             con.Open();
44             string sql = "select *from SinhVien where MaLop=@MaLop";
45             SqlDataAdapter da = new SqlDataAdapter(sql, con);
46             da.SelectCommand.Parameters.AddWithValue("@MaLop", cmbMaLop.SelectedValue.ToString());
47             DataTable dt = new DataTable();
48             da.Fill(dt);
49             crBaoCao cr = new crBaoCao();
50             ConnectionInfo crConnectionInfo = new ConnectionInfo();
51             crConnectionInfo.ServerName = "Ty-PC";
52             crConnectionInfo.DatabaseName = "CNPM_1";
53             crConnectionInfo.UserID = "sa";
54             crConnectionInfo.Password = "04091990";
55             TableLogOnInfos crTableLogonInfos = new TableLogOnInfos();
56             foreach (CrystalDecisions.CrystalReports.Engine.Table table in cr.Database.Tables)
57             {
58                 TableLogOnInfo crTableLogonInfo = new TableLogOnInfo();
59                 crTableLogonInfo.TableName = table.Name;
60                 crTableLogonInfo.ConnectionInfo = crConnectionInfo;
61                 crTableLogonInfos.Add(crTableLogonInfo);
62                 table.ApplyLogOnInfo(crTableLogonInfo);
63
64             }
65             crvHocKyHocPhan.LogOnInfo = crTableLogonInfos;
66             cr.SetDataSource(dt);
67             ParameterValues a = new ParameterValues();
68             ParameterDiscreteValue b = new ParameterDiscreteValue();
69             b.Value = cmbMaLop.SelectedValue.ToString();
70             a.Add(b);
71             cr.DataDefinition.ParameterFields["txtMaLop"].ApplyCurrentValues(a);
72             crvHocKyHocPhan.ReportSource = cr;
73             crvHocKyHocPhan.Show();
74         }
File name: FormKHGD.cs Copy
20         private void FormKHGD_Load(object sender, EventArgs e)
21         {
22             // TODO: This line of code loads data into the 'cNPM_1DataSet5.KhoiLop' table. You can move, or remove it, as needed.
23             this.khoiLopTableAdapter.Fill(this.cNPM_1DataSet_KhoiLop.KhoiLop);
24             // TODO: This line of code loads data into the 'cNPM_1DataSet4.HocKy' table. You can move, or remove it, as needed.
25             this.hocKyTableAdapter.Fill(this.cNPM_1DataSet_HocKy.HocKy);
26             dgvKHGD.DataSource = business.ShowData("KeHoachGiangDay");
27         }
File name: FormKhoiLop.cs Copy
20         private void FormKhoiLop_Load(object sender, EventArgs e)
21         {
22             // TODO: This line of code loads data into the 'cNPM_1DataSet3.TrinhDoDaoTao' table. You can move, or remove it, as needed.
23             this.trinhDoDaoTaoTableAdapter.Fill(this.cNPM_1DataSet_TrinhDoDaoTao.TrinhDoDaoTao);
24             // TODO: This line of code loads data into the 'cNPM_1DataSet2.HeDaoTao' table. You can move, or remove it, as needed.
25             this.heDaoTaoTableAdapter.Fill(this.cNPM_1DataSet_HeDaoTao.HeDaoTao);
26             dgvKhoiLop.DataSource = business.ShowData("KhoiLop");
27         }

Download file with original file name:Set

Set 132 lượt xem

Gõ tìm kiếm nhanh...