Visual Basic, C & C++
분류 Delphi

델파이에서 ie 창 띄우기

페이지 정보

본문

uses 
  ComObj;

procedure TForm1.Button1Click(Sender: TObject);
var                                            // uses 구문에 'ComObj'를 추가
  IE: Variant; 
  WinHandle: HWND; 
begin 
  if VarIsEmpty(IE) then 
    begin
      IE := CreateOLEObject('InternetExplorer.Application');
      IE.Visible := True;
      IE.Navigate('http://www.nuno21.net/');
    end
  else
    begin
      WinHandle := FindWindow('IEFrame', nil);

      if 0 <> WinHandle then
        begin
          IE.Navigate('http://www.nuno21.net/');
          SetForeGroundWindow(WinHandle);
        end;
    end;

end;
end.

관련자료

등록된 댓글이 없습니다.
프로그래밍
Today's proverb
“힘내라구.” 밤에 헤어질 때, 아주 좋은 이야기를 나누었을 때든지 아무 관련 없이 로댕은 곧잘 내게 이렇게 말하는 것이었습니다. 그는 알고 있었던 겁니다. 젊었을 때, 이 말이 날마다 얼마나 필요한 것인가를. (릴케)