Page 1 of 1

Uniconnection.GetTableNames

Posted: Fri 23 Nov 2012 11:28
by isysoftware
Hi All,

with this code, (radstudio 2007, Unidac 4.5.9), I have an Abstract Error on line UniConnection1.GetTableNames(alst);

Code: Select all

function TForm1.LeggiTabelle: boolean;
var aLst:TWideStrings;
begin
      if(UniConnection1.Connected = true) then
          begin
              aLst:=TWideStrings.Create;
              //aLst.Clear;
              UniConnection1.GetTableNames(alst);
              if(Assigned(aLst)) then
                 begin
                      if(aLst.Count > 0) then
                          showmessage('OK')
                      else
                         ShowMessage('KO');
                 end;
          end
      else
         result:=false;
end;
Can you help me?

Re: Uniconnection.GetTableNames

Posted: Fri 23 Nov 2012 13:11
by AlexP
Hello,

The TWideStrings class includes Clear, Insert, Delete abstract methods (corresponding messages are displayed when compiling), and when calling one of these methods (Clear particularly), you get this error. To solve the problem, you should modify your code in the following way:

aLst:= TWideStringList.Create;