Exemple #1
0
 private void button1_Click_1(object sender, EventArgs e)
 {
     using (var query = new Query())
     {
         query.Add("email", "e", NpgsqlDbType.Text);
         var a             = query.ExecuteNonQuery();
         var v             = query.FillData();
         var dataTableJson = new DataTableJsonConverter();
         var json          = dataTableJson.ConvertToJson(v);
         MessageBox.Show(json);
     }
 }
Exemple #2
0
 private void button2_Click(object sender, EventArgs e)
 {
     using (var query = new Query())
     {
         try
         {
             query.Add("email", "e", NpgsqlDbType.Text);
             var a             = query.ExecuteNonQuery();
             var v             = query.FillData();
             var dataTableJson = new DataTableJsonConverter();
             var json          = dataTableJson.ConvertToJson(v);
             var dataTable     = dataTableJson.ConvertToDataTable(json);
             MessageBox.Show("success");
         }
         catch (Exception exception)
         {
             MessageBox.Show(exception.Message);
         }
     }
 }