全部显示

TargetBrowser 属性

       

返回或设置 MsoTargetBrowser 常量,表明对指定的数据访问页或对于所有数据访问页而言,哪一种是理想的 Web 浏览器。可读写。

expression.TargetBrowser

expression   必需。返回“Applies To”列表中的一个对象的表达式。

示例

如果当前的目标浏览器是 Internet Explorer 的早期版本,则该示例将活动数据访问页的目标浏览器设为 Microsoft Internet Explorer 6。

With Screen.ActiveDataAccessPage.WebOptions
    If .TargetBrowser = msoTargetBrowserIE4 Or _
            .TargetBrowser = msoTargetBrowserIE5 Then
        .TargetBrowser = msoTargetBrowserIE6
    End If
End With

该示例将所有数据访问页的目标浏览器都设为 Internet Explorer 6。

Application.DefaultWebOptions _
    .TargetBrowser = msoTargetBrowserIE6