public static int FL_odbc_execute_command(string Constring, string SqlCommand) { var r = 0; try { var Connection = new OdbcConnection(Constring); var Cmd = new OdbcCommand(SqlCommand, Connection); r = Cmd.ExecuteCommand(); } catch (OleDbException e) { MessageBox.Show("Error : " + e.Message, "Error", MessageBoxButton.OK, MessageBoxImage.Error); } return(r); }