using System;
using System.Drawing;
using System.Collections;
using System.ComponentModel;
using System.Windows.Forms;
using System.Data;
using System.Data.OleDb;
public class Form1 : System.Windows.Forms.Form
{
private DataView dv;
private DataView dv1;
private System.Windows.Forms.DataGrid dg1;
private System.Windows.Forms.DataGrid dg2;
private System.Windows.Forms.Button button1;
private System.ComponentModel.Container components = null;
private void BuildTable()
{
string ConStr = ("Provider=MSDAORA;data source=bitcamp2;User ID=scott;Password=tiger");
OleDbConnection Conn = new OleDbConnection(ConStr);
OleDbDataAdapter da = new OleDbDataAdapter("SELECT * FROM emp", Conn);
DataSet ds = new DataSet("MYDATASET");
da.Fill(ds, "EMP");
dv = new DataView(ds.Tables["EMP"],
"empno>5000",
"empno",
DataViewRowState.CurrentRows);
dv1 = new DataView(ds.Tables["EMP"],
"ename like '%S%'",
"empno",
DataViewRowState.CurrentRows);
}
public Form1()
{
InitializeComponent();
BuildTable();
}
protected override void Dispose( bool disposing )
{
if( disposing )
{
if (components != null)
{
components.Dispose();
}
}
base.Dispose( disposing );
}
private void InitializeComponent()
{
this.dg1 = new System.Windows.Forms.DataGrid();
this.dg2 = new System.Windows.Forms.DataGrid();
this.button1 = new System.Windows.Forms.Button();
((System.ComponentModel.ISupportInitialize)(this.dg1)).BeginInit();
((System.ComponentModel.ISupportInitialize)(this.dg2)).BeginInit();
this.SuspendLayout();
//
// dg1
//
this.dg1.DataMember = "";
this.dg1.HeaderForeColor = System.Drawing.SystemColors.ControlText;
this.dg1.Location = new System.Drawing.Point(8, 8);
this.dg1.Name = "dg1";
this.dg1.Size = new System.Drawing.Size(680, 192);
this.dg1.TabIndex = 0;
//
// dg2
//
this.dg2.DataMember = "";
this.dg2.HeaderForeColor = System.Drawing.SystemColors.ControlText;
this.dg2.Location = new System.Drawing.Point(8, 208);
this.dg2.Name = "dg2";
this.dg2.Size = new System.Drawing.Size(680, 160);
this.dg2.TabIndex = 3;
//
// button1
//
this.button1.Location = new System.Drawing.Point(496, 384);
this.button1.Name = "button1";
this.button1.Size = new System.Drawing.Size(96, 26);
this.button1.TabIndex = 2;
this.button1.Text = "Fill";
this.button1.Click += new System.EventHandler(this.button1_Click);
//
// Form1
//
this.AutoScaleBaseSize = new System.Drawing.Size(6, 14);
this.ClientSize = new System.Drawing.Size(696, 421);
this.Controls.AddRange(new System.Windows.Forms.Control[] {
this.button1,
this.dg2,
this.dg1});
this.Name = "Form1";
this.Text = "Form1";
((System.ComponentModel.ISupportInitialize)(this.dg1)).EndInit();
((System.ComponentModel.ISupportInitialize)(this.dg2)).EndInit();
this.ResumeLayout(false);
}
[STAThread]
static void Main()
{
Application.Run(new Form1());
}
private void button1_Click(object sender, System.EventArgs e)
{
dg1.SetDataBinding(dv1, "");
dg2.SetDataBinding(dv, "");
}
}
using System.Drawing;
using System.Collections;
using System.ComponentModel;
using System.Windows.Forms;
using System.Data;
using System.Data.OleDb;
public class Form1 : System.Windows.Forms.Form
{
private DataView dv;
private DataView dv1;
private System.Windows.Forms.DataGrid dg1;
private System.Windows.Forms.DataGrid dg2;
private System.Windows.Forms.Button button1;
private System.ComponentModel.Container components = null;
private void BuildTable()
{
string ConStr = ("Provider=MSDAORA;data source=bitcamp2;User ID=scott;Password=tiger");
OleDbConnection Conn = new OleDbConnection(ConStr);
OleDbDataAdapter da = new OleDbDataAdapter("SELECT * FROM emp", Conn);
DataSet ds = new DataSet("MYDATASET");
da.Fill(ds, "EMP");
dv = new DataView(ds.Tables["EMP"],
"empno>5000",
"empno",
DataViewRowState.CurrentRows);
dv1 = new DataView(ds.Tables["EMP"],
"ename like '%S%'",
"empno",
DataViewRowState.CurrentRows);
}
public Form1()
{
InitializeComponent();
BuildTable();
}
protected override void Dispose( bool disposing )
{
if( disposing )
{
if (components != null)
{
components.Dispose();
}
}
base.Dispose( disposing );
}
private void InitializeComponent()
{
this.dg1 = new System.Windows.Forms.DataGrid();
this.dg2 = new System.Windows.Forms.DataGrid();
this.button1 = new System.Windows.Forms.Button();
((System.ComponentModel.ISupportInitialize)(this.dg1)).BeginInit();
((System.ComponentModel.ISupportInitialize)(this.dg2)).BeginInit();
this.SuspendLayout();
//
// dg1
//
this.dg1.DataMember = "";
this.dg1.HeaderForeColor = System.Drawing.SystemColors.ControlText;
this.dg1.Location = new System.Drawing.Point(8, 8);
this.dg1.Name = "dg1";
this.dg1.Size = new System.Drawing.Size(680, 192);
this.dg1.TabIndex = 0;
//
// dg2
//
this.dg2.DataMember = "";
this.dg2.HeaderForeColor = System.Drawing.SystemColors.ControlText;
this.dg2.Location = new System.Drawing.Point(8, 208);
this.dg2.Name = "dg2";
this.dg2.Size = new System.Drawing.Size(680, 160);
this.dg2.TabIndex = 3;
//
// button1
//
this.button1.Location = new System.Drawing.Point(496, 384);
this.button1.Name = "button1";
this.button1.Size = new System.Drawing.Size(96, 26);
this.button1.TabIndex = 2;
this.button1.Text = "Fill";
this.button1.Click += new System.EventHandler(this.button1_Click);
//
// Form1
//
this.AutoScaleBaseSize = new System.Drawing.Size(6, 14);
this.ClientSize = new System.Drawing.Size(696, 421);
this.Controls.AddRange(new System.Windows.Forms.Control[] {
this.button1,
this.dg2,
this.dg1});
this.Name = "Form1";
this.Text = "Form1";
((System.ComponentModel.ISupportInitialize)(this.dg1)).EndInit();
((System.ComponentModel.ISupportInitialize)(this.dg2)).EndInit();
this.ResumeLayout(false);
}
[STAThread]
static void Main()
{
Application.Run(new Form1());
}
private void button1_Click(object sender, System.EventArgs e)
{
dg1.SetDataBinding(dv1, "");
dg2.SetDataBinding(dv, "");
}
}
오라클자바커뮤니티교육센터, 개발자전문교육, 개인80%환급
www.oraclejavacommunity.com
평일주간(9:30~18:10) 개강
(7/21)[기업100%환급]자바기초에서 JDBC, Servlet/JSP까지
(7/21)[기업100%환급]Spring ,MyBatis,Hibernate실무과정
(7/21)[기업100%환급]PL/SQL,ORACLE HINT,TUNING
(7/21)[채용예정교육]오라클자바개발잘하는신입뽑기프로젝트,교육전취업확정
(7/28)[기업100%환급]C#4.0,WinForm,ADO.NET프로그래밍
(7/28)[기업100%환급]안드로이드개발자과정
(7/28)[기업100%환급]SQL기초에서 Schema Object까지
평일야간(19:00~21:50) 개강
(7/21)웹퍼블리싱 마스터
(7/22)자바기초에서JSP,Ajax,jQuery,Spring3.2,MyBatis까지
(7/22)닷넷(C#,Network,ADO.NET,ASP.NET)마스터과정
(7/24)SQL기초에서실무까지
(7/29)안드로이드개발자과정
(7/29)Spring3.X, MyBatis, Hibernate실무과정
(8/05)MyBatis3.X, Hibernate4.X ORM실무과정
주말(10:00~17:50) 개강
(7/19)JSP,Ajax,jQUERY,Spring,MyBatis,Hibernate속성과정
(7/19)SQL초보에서 Schema Object까지
(7/19)C#,ASP.NET마스터
(7/19)Spring3.X, MyBatis, Hibernate실무과정
(7/19)웹퍼블리싱 마스터
(7/19)안드로이드개발자과정
(7/26)개발자를위한PLSQL,SQL튜닝,힌트
(8/02)MyBatis3.X, Hibernate4.X ORM실무과정
(8/09)자바기초에서JSP,Ajax,jQuery,Spring3.2,MyBatis까지
(8/23)JAVA,Network&WEB&Framework(자바기초에서웹스프링까지)
주말저녁(18:30~22:20) 개강
(8/02)JAVA,Network&WEB&Framework
(8/09)SQL기초에서실무까지
www.oraclejavacommunity.com
평일주간(9:30~18:10) 개강
(7/21)[기업100%환급]자바기초에서 JDBC, Servlet/JSP까지
(7/21)[기업100%환급]Spring ,MyBatis,Hibernate실무과정
(7/21)[기업100%환급]PL/SQL,ORACLE HINT,TUNING
(7/21)[채용예정교육]오라클자바개발잘하는신입뽑기프로젝트,교육전취업확정
(7/28)[기업100%환급]C#4.0,WinForm,ADO.NET프로그래밍
(7/28)[기업100%환급]안드로이드개발자과정
(7/28)[기업100%환급]SQL기초에서 Schema Object까지
평일야간(19:00~21:50) 개강
(7/21)웹퍼블리싱 마스터
(7/22)자바기초에서JSP,Ajax,jQuery,Spring3.2,MyBatis까지
(7/22)닷넷(C#,Network,ADO.NET,ASP.NET)마스터과정
(7/24)SQL기초에서실무까지
(7/29)안드로이드개발자과정
(7/29)Spring3.X, MyBatis, Hibernate실무과정
(8/05)MyBatis3.X, Hibernate4.X ORM실무과정
주말(10:00~17:50) 개강
(7/19)JSP,Ajax,jQUERY,Spring,MyBatis,Hibernate속성과정
(7/19)SQL초보에서 Schema Object까지
(7/19)C#,ASP.NET마스터
(7/19)Spring3.X, MyBatis, Hibernate실무과정
(7/19)웹퍼블리싱 마스터
(7/19)안드로이드개발자과정
(7/26)개발자를위한PLSQL,SQL튜닝,힌트
(8/02)MyBatis3.X, Hibernate4.X ORM실무과정
(8/09)자바기초에서JSP,Ajax,jQuery,Spring3.2,MyBatis까지
(8/23)JAVA,Network&WEB&Framework(자바기초에서웹스프링까지)
주말저녁(18:30~22:20) 개강
(8/02)JAVA,Network&WEB&Framework
(8/09)SQL기초에서실무까지
댓글 없음:
댓글 쓰기