请问各位大虾,有谁做过双显卡的程序(100分)

  • 主题发起人 bigheadhy
  • 开始时间
B

bigheadhy

Unregistered / Unconfirmed
GUEST, unregistred user!
请问各位大虾,有谁做过双显卡的程序,第二屏的坐标怎么设定,1024*768 我设定第二屏的坐标为
(1025,0)结果显示的还是在第一屏上,请各位大虾帮忙!
 
procedure SetWindowToMonitor(Form: TCustomForm; // 你想操作的窗体
MonitorIndex, // 你想要显示窗体的显示
// 器索引, 0为主显示
// 器,1为第二显示器
ALeft, ATop: Integer // 窗体在显示器上的位置
);
begin
if not Assigned(Form) then Exit;
if MonitorIndex >= Screen.MonitorCount then Exit;
with Screen do
begin
Inc(ALeft, Monitors[MonitorIndex].Left);
Inc(ATop, Monitors[MonitorIndex].Top);
end;
Form.SetBounds(ALeft, ATop, Form.Width, Form.Height);
end;
 
谢了,测试通过了~!
 
顶部