Sign in Join

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

Mailing lists / lazarus / 2016-01

Win API function calls with array as parameter

3 messages · 2 people · –

Reply by email Subscribe to this list Your subscription

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

Michael W. Vogel
to John Landmesser

You can try:

TileWindows(0, MDITILE_HORIZONTAL, Screen.WorkAreaRect,
Length(MyHandles), MyHandles[0]);

or

TileWindows(0, MDITILE_HORIZONTAL, Screen.WorkAreaRect, High(MyHandles)
+ 1, MyHandles[0]);

Simple Test works for me:

uses
   ..., windows, LCLType;
procedure TForm1.Button1Click(Sender: TObject);
var
   Wnds: array[0..1] of HWND;
begin
   Wnds[0] := Handle;
   Wnds[1] := Form2.Handle;
   TileWindows(0, MDITILE_HORIZONTAL, Screen.WorkAreaRect, Length(Wnds),
Wnds[0]);
end;

Reply by email