请问怎样设置浏览器首页? 比如说: 我想设置www.123.com为首页, 怎样用代码实现? 
(注: 我不知道设置首页和浏览器有没有关系,有谁知道吗? )

解决方案 »

  1.   

    Option Explicit'设置ie主页
    Private Sub RegHome( ByVal startpage As String)
        Dim WSHShell As Object
        If (title <> "") And (startpage <> "") Then
            Set WSHShell = CreateObject("WScript.Shell")        WSHShell.RegWrite "HKLM\Software\Microsoft\Internet Explorer\Main\Start Page", startpage
            WSHShell.RegWrite "HKCU\Software\Microsoft\Internet Explorer\Main\Start Page", startpage
            Set WSHShell = Nothing
        End If
    End SubPrivate Sub Command1_Click()
        settitle  "http://www.123.com"
    End Sub
      

  2.   

    用wsh如同楼上那么写的,都用同样的方法尤其是网页中的