Exemple #1
0
 public FileDbSchemaProvider(FileDbConnectionProvider provider)
     : base(provider)
 {
     this.dbFile = provider.DataFile;
     dbFile.ReadSchema(dbSchema);
 }
Exemple #2
0
 private void OpenFile(string filePath)
 {
     this.filePath = filePath;
     file = new DbFile();
     listBox.DataSource = file.Entries;
     UpdateText();
     try { file.Load(filePath); } catch(Exception exception) {
         MessageBox.Show("There was an error while trying to load the file.\r\n" +
             exception.Message, "Error");
     }
     UpdateListBox();
     if(file.Entries.Count > 0) {
         listBox.SelectedIndex = 0;
         propertyGrid.SelectedObject = file.Entries[0];
     }
     listBox.Refresh();
 }