Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- private void loadingData()
- {
- this.makeConnection();
- Console.WriteLine("\nBegin loading data...");
- try
- {
- OracleCommand command = new OracleCommand("SELECT * FROM PHONEBOOK", connection);
- OracleDataAdapter adapter = new OracleDataAdapter(command);
- DataTable table = new DataTable();
- adapter.Fill(table);
- dataGridViewPhonebook.DataSource = table;
- Console.WriteLine("Success loading data...");
- this.closeConnection();
- }
- catch (Exception ex)
- {
- Console.WriteLine("Failed to load data :: " + ex.Message);
- }
- }
Advertisement
Add Comment
Please, Sign In to add comment