Changeset 26 for trunk/Forms/UFormTables.pas
- Timestamp:
- Sep 10, 2022, 8:03:08 PM (2 years ago)
- Location:
- trunk
- Files:
-
- 2 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk
- Property svn:ignore
-
old new 7 7 heaptrclog.trc 8 8 MyData.exe 9 MyData.dbg 10
-
- Property svn:ignore
-
trunk/Forms/UFormTables.pas
r24 r26 1 1 unit UFormTables; 2 3 {$mode delphi}{$H+}4 2 5 3 interface … … 7 5 uses 8 6 Classes, SysUtils, FileUtil, Forms, Controls, Graphics, Dialogs, ComCtrls, 9 ActnList, Menus, UDatabase , SpecializedDictionary;7 ActnList, Menus, UDatabase; 10 8 11 9 type … … 38 36 procedure AShowFieldsExecute(Sender: TObject); 39 37 procedure AShowRecordsExecute(Sender: TObject); 40 procedure FormActivate(Sender: TObject);41 procedure FormClose(Sender: TObject; var CloseAction: TCloseAction);42 38 procedure FormCreate(Sender: TObject); 43 39 procedure FormDestroy(Sender: TObject); … … 60 56 FormTables: TFormTables; 61 57 58 62 59 implementation 63 60 … … 71 68 SRemoveTableConfirm = 'Do you want to really remove table ''%s'' ?'; 72 69 SNewTable = 'New table'; 73 74 70 75 71 { TFormTables } … … 202 198 end; 203 199 204 procedure TFormTables.FormActivate(Sender: TObject);205 begin206 end;207 208 procedure TFormTables.FormClose(Sender: TObject; var CloseAction: TCloseAction);209 begin210 end;211 212 200 procedure TFormTables.FormCreate(Sender: TObject); 213 201 begin … … 217 205 procedure TFormTables.FormDestroy(Sender: TObject); 218 206 begin 219 F Tables.Free;207 FreeAndNil(FTables); 220 208 end; 221 209 … … 241 229 DbClient.Query('SELECT * FROM Model', DbRows); 242 230 for I := 0 to DbRows.Count - 1 do begin 243 NewTable := Tables.AddNew( TDictionaryStringString(DbRows[I]).Values['Name']);244 NewTable.Caption := TDictionaryStringString(DbRows[I]).Values['Caption'];231 NewTable := Tables.AddNew(DbRows[I].Items['Name']); 232 NewTable.Caption := DbRows[I].Items['Caption']; 245 233 end; 246 234 DbRows.Free;
Note:
See TracChangeset
for help on using the changeset viewer.