Sign in Join

Live chat for Free Pascal, Lazarus, Delphi and every Pascal programmer.

Mailing lists / lazarus / 2014-05

Form in tab on Windows=>Failed to create win32 control, error: 0

3 messages · 1 person · –

Reply by email Subscribe to this list Your subscription

Read-only archive. Use j and k to move between messages.

Reinier Olislagers

In Turbobird
https://github.com/motaz/turbobird

when connected to a database, going to views/right click, Display View DDL gives an error message instead of the expected form in a tab.

Error message:
Failed to create win32 control, error: 0 : The operation completed succesfully
It occurs
- in the development version (Laz trunk, as well as Laz 1.2.2) as well as release version TurboBird for Win32 1.0.2
- on my Windows7 system, as well as a Windows 2000 system

It does NOT occur on Wine on Debian unstable.
No problems on Linux. Other forms that are created in a similar way work ok.

The form is being created in a tabsheet:
procedure TfmMain.lmDisplayViewClick(Sender: TObject);
...
    // Fill ViewView grid
    ATab:= TTabSheet.Create(self);
    ATab.Parent:= PageControl1;
    fmViewView:= TfmViewView.Create(nil);
    fmViewView.Parent:= ATab;

if I comment out the last line, the bug does not occur.

Is this code incorrect or is there a problem with tabsheets and this form?

Thanks,
Reinier

Reply by email

Reinier Olislagers
to Reinier Olislagers
Reinier Olislagers wrote
Error message: Failed to create win32 control, error: 0 : The operation completed succesfully

I found that removing
AlphaBlend = True
in the offending form's .lfm file solves the problem.

Is this expected behaviour or a Lazarus bug connected with tabsheets?

Thanks,
Reinier

Reply by email