摘要:
uses ShellAPI;procedure TForm1.FormCreate(Sender: TObject);begin DragAcceptFiles(Handle, True);end;procedure TForm1.WMDropFiles(var Message: TWMDropFiles);var p: array[0..255] of Char; i,count: Integer;begin {先获取拖拽的文件总数} count := DragQueryFile(message.Drop, $FFFFFFFF, nil, 0); {分别获取文件名} for i... 阅读全文
posted @ 2012-04-06 13:15
ftwsnow
阅读(146)
评论(0)
推荐(0)
摘要:
procedure TForm1.Timer1Timer(Sender: TObject);var pt: TPoint; arr: array[0..254] of Char;begin if GetCursorPos(pt) then {如果能获取点} begin h := WindowFromPoint(pt); {返回句柄} GetClassName(h, arr, Length(arr)); {获取该句柄窗口的类名} Text := arr; {显示在标题} end;end; 阅读全文
posted @ 2012-04-06 10:05
ftwsnow
阅读(178)
评论(0)
推荐(0)

浙公网安备 33010602011771号