请问在窗体上已有网址,单击即可连接到该网页,用什么组件?

解决方案 »

  1.   

    随便什么都可以,例如用TLabel,在TLabel的OnClick事件中写
    ShellExecute(Application.Handle,'open',PChar(Label1.Caption),'','',1);
    就可以了。记得要use ShellAPI
      

  2.   

    api函数的啊需要use shellapi的
     ShellExecute(Handle, 'OPEN',
        PChar('http'www.6to23.com'), nil, nil, sw_shownormal);
      

  3.   

    网址的内容用Label显示,
    Label1.Caption := 'www.csdn.net';
    并设光标为手形
    在Label的OnClick事件中写:ShellExecute(0, nil, PChar(label1.Caption), nil, nil, SW_NORMAL);
    别忘在uses中添加:
    ShellApi;