Guest User

Untitled

a guest
Jan 22nd, 2019
87
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 1.22 KB | None | 0 0
  1. using System;
  2. using System.Collections.Generic;
  3. using System.ComponentModel;
  4. using System.Data;
  5. using System.Drawing;
  6. using System.Linq;
  7. using System.Text;
  8. using System.Windows.Forms;
  9. using System.Data.OleDb;
  10.  
  11.  
  12.  
  13.  
  14.  
  15. namespace corrigécollefinale
  16. {
  17. public partial class Form1 : Form
  18. {
  19. public Form1()
  20. {
  21. InitializeComponent();
  22. }
  23.  
  24. OleDbConnection connec = new OleDbConnection();
  25. string chcon = @"Provider=Microsoft.Jet.OLEDB.4.0;Data Source=C:\Users\Cakess\Documents\G21\Voyages2010.mdb";
  26. DataSet dsLocal = new DataSet();
  27.  
  28.  
  29. private void Form1_Load(object sender, EventArgs e)
  30. {
  31.  
  32. ChargementDslocal();
  33. }
  34.  
  35. private void ChargementDslocal()
  36. {
  37. connec.ConnectionString = chcon;
  38. DataTable schema = connec.GetOleDbSchemaTable(OleDbSchemaGuid.Tables, new Object[] (null,null,null));
  39. int n = schema.Rows.Count();
  40. OleDbDataAdapter da = new OleDbDataAdapter();
  41.  
  42. for(int i = 0; i<n;i++)
  43. {
  44. DataRow ligne = schema.Rows.Count;
  45. }
  46. }
  47.  
  48.  
  49. }
  50. }
Add Comment
Please, Sign In to add comment