打印本文 打印本文 关闭窗口 关闭窗口
通过c#连结oracle数据库(三)
作者:武汉SEO闵涛  文章来源:敏韬网  点击数3078  更新时间:2009/4/22 22:10:38  文章录入:mintao  责任编辑:mintao
Comm = new OleDbCommand(Str2,Conn);

Comm.ExecuteNonQuery();

MessageBox.Show("Record has been deleted!");

TxtEmpNo.Text = "";

TxtEName.Text = "";

TxtESal.Text = "";

TxtDeptNo.Text = "";

TxtEmpNo.Focus();

}

}

catch(Exception ex)

{

MessageBox.Show(ex.Message);

}

}

}

}

using System;

using System.Drawing;

using System.Collections;

using System.ComponentModel;

using System.Windows.Forms;

using System.Data;

using System.Data.OleDb;

namespace Employee

{

/// <summary>

/// Summary description for Form1.

/// </summary>

public class FrmEmp : System.Windows.Forms.Form

{

private System.Windows.Forms.Label label1;

private System.Windows.Forms.Label label2;

private System.Windows.Forms.Label label3;

private System.Windows.Forms.Label label4;

private System.Windows.Forms.TextBox TxtEmpNo;

private System.Windows.Forms.TextBox TxtEName;

private System.Windows.Forms.TextBox TxtESal;

private System.Windows.Forms.TextBox TxtDeptNo;

private System.Windows.Forms.Button BtnAddNew;

private System.Windows.Forms.Button BtnSave;

private System.Windows.Forms.Button BtnDelete;

private System.Windows.Forms.Button BtnExit;

private System.Data.OleDb.OleDbConnection Conn;

private System.Data.OleDb.OleDbCommand Comm;

private System.Data.OleDb.OleDbDataAdapter DataAdpt;

private System.Data.OleDb.OleDbCommandBuilder CBuild;

private System.Data.OleDb.OleDbDataReader DtRead;

private System.Data.DataSet DataSet1;

private System.Data.DataRow DataRow1;

private System.Data.DataTable DataTable1;

private string ConnStr;

private bool blnEdit;

private System.Windows.Forms.Button BtnEdit;

/// <summary>

/// Required designer variable.

/// </summary>

private System.ComponentModel.Container components = null;

public FrmEmp()

{

//

// Required for Windows Form Designer support

//

InitializeComponent();

上一页  [1] [2] [3] [4]  下一页

打印本文 打印本文 关闭窗口 关闭窗口