Ignore:
Timestamp:
Jan 25, 2025, 12:11:20 PM (8 days ago)
Author:
chronos
Message:
  • Fixed: Error on new acronym cateogry addition.
  • Added: New import source from Wikipedia aviation acronyms.
File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/Forms/FormCategories.pas

    r230 r231  
    8989var
    9090  S: string;
     91  NewCategory: TAcronymCategory;
    9192begin
    9293  S := InputBox(SCategory, SCategoryQuery, '');
    9394  if S <> '' then begin
    9495    if not Assigned(AcronymDb.Categories.SearchByName(S)) then begin;
    95       TAcronymCategory(AcronymDb.Categories[AcronymDb.Categories.Add(TAcronymCategory.Create)]).Name := S;
     96      NewCategory := TAcronymCategory.Create;
     97      NewCategory.AcronymDb := Categories.Db;
     98      NewCategory.Name := S;
     99      Categories.Add(NewCategory);
     100
    96101      AcronymDb.Modified := True;
    97102      AcronymDb.Update;
Note: See TracChangeset for help on using the changeset viewer.