Atozed Forums
bug in FillRealTabOrders - Printable Version

+- Atozed Forums (https://www.atozed.com/forums)
+-- Forum: Atozed Software Products (https://www.atozed.com/forums/forum-1.html)
+--- Forum: IntraWeb (https://www.atozed.com/forums/forum-3.html)
+---- Forum: English (https://www.atozed.com/forums/forum-16.html)
+----- Forum: IntraWeb General Discussion (https://www.atozed.com/forums/forum-4.html)
+----- Thread: bug in FillRealTabOrders (/thread-1814.html)



bug in FillRealTabOrders - mazluta - 07-16-2020

hi think there is bug in - the list is not maintained correctly and some of the obj in the list don't exists 
so - the render crash

------------------------------------  this is my bypass

procedure TIWForm.FillRealTabOrders;

  procedure FillList(AContainer: TIWContainer; AList: TIWListBase);
  var
    i: Integer;
    LCurrent: TObject;
    LTabOrderInterface: IIWTabOrder;
  begin
    for i := 0 to AContainer.TabOrderList.Count - 1 do
    begin
      Try //Yossi
        LCurrent := TObject(AContainer.TabOrderList[i]);
        if Assigned(LCurrent) then //yossi
        begin
        if LCurrent is TIWContainer then
        begin
          FillList(TIWContainer(LCurrent), AList);
        end
        else
        begin
          LTabOrderInterface := TabOrderInterface(LCurrent);
          if LTabOrderInterface <> nil then begin
            if LTabOrderInterface.HasTabOrder then begin
            AList.Add(LCurrent);
            end;
          end;
        end;
        end;
      Except //yossi
        on e: exception do
        begin
          Try
            logFileAppend('Error on  TabOrder FillList : I= ' + IntToStr(I) + ' Message= ' + e.Message);
          Except;
          End;
        end;
      End;
    end;
  end;

begin
  FRealTabOrderList := TIWListBase.Create;
  FillList(Self, FRealTabOrderList);
end;


RE: bug in FillRealTabOrders - Alexandre Machado - 07-17-2020

What version is that?

The code is correct. The problem usually comes from controls without parent being created and destroyed on the fly which bypass the TComponent notification mechanism completely. Are you doing it?


RE: bug in FillRealTabOrders - mazluta - 07-17-2020

15.2.4
the is correct. but the list is not maintained correctly, so i gat access violation.
i have some frames and inside frame. when i free one frame and try to create another. i think, it try to render the freed frame.


RE: bug in FillRealTabOrders - kudzu - 07-17-2020

Please post a ready to run demo that demonstrates your issue for us to see. Posting code snippets not only often leaves out code that is important and interacts, but slows down support requests as we have to try to recreate the issue from code snippets.


RE: bug in FillRealTabOrders - Alexandre Machado - 07-17-2020

(07-17-2020, 08:04 AM)mazluta Wrote: 15.2.4
the is correct. but the list is not maintained correctly, so i gat access violation.
i have some frames and inside frame. when i free one frame and try to create another. i think, it try to render the freed frame.

Update to latest 15.2.6. Check the version history here:

https://www.atozed.com/2020/07/15-2-5-h/





RE: bug in FillRealTabOrders - mazluta - 07-18-2020

after install 15.2.6

no help

(07-18-2020, 02:55 PM)mazluta Wrote: after install 15.2.6

no help


please see - attached -  project 1


RE: bug in FillRealTabOrders - Alexandre Machado - 07-20-2020

The attached demo project doesn't crash using latest 15.2.6. Have you tested it?

The issue that you claim that is not working is a rendering issue regarding jQGrid which you reported again in another thread.