Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- private void btnSendEmails_Click(object sender, EventArgs e)
- {
- string userName = txtUsername.Text;
- string password = txtPassword.Text;
- string tableSpace = txtTableSpace.Text;
- string tableName = txtTableName.Text;
- string statement = "Select * FROM " + tableName;
- //create the connection to Oracle using the above log in information
- string connectionString = "Provider=OraOLEDB.Oracle;Data Source=" + tableSpace + ";User Id=" + userName + ";Password=" + password + ";";
- System.Data.OleDb.OleDbConnection cnn = new System.Data.OleDb.OleDbConnection(connectionString);
- cnn.Open();
- System.Data.OleDb.OleDbDataAdapter Dadpt = new System.Data.OleDb.OleDbDataAdapter(statement, cnn);
- DataSet ds = new DataSet();
- Dadpt.Fill(ds);
- cnn.Close();
- //OpenFileDialog attachment;
- CreateRTFMailItem(ds);
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement