LocationDisp.CivicAddressReportFactory 对象
[位置 API 对象模型可用于“要求”部分中指定的操作系统。 它可能在后续版本中变更或不可用。 相反,若要从网站访问位置,请使用 W3C 地理位置 API。 若要从桌面应用程序访问位置,请使用 Windows.Devices.Geolocation API。]
管理市政地址报告。
成员
LocationDisp.CivicAddressReportFactory 对象包含以下类型的成员:
方法
LocationDisp.CivicAddressReportFactory 对象具有以下方法。
方法 | 说明 |
---|---|
ListenForReports | 请求市政地址报告事件。 |
RequestPermissions | 打开一个系统对话框,以请求启用位置的设备的用户权限。 |
StopListeningForReports | 取消市政地址报告事件请求。 |
属性
LocationDisp.CivicAddressReportFactory 对象具有这些属性。
属性 | 访问类型 | 说明 |
---|---|---|
CivicAddressReport |
只读 |
当前 LocationDisp.DispCivicAddressReport。 |
DesiredAccuracy |
读取/写入 |
当前所需的准确度设置。 |
ReportInterval |
读取/写入 |
当前市政地址报告事件间隔(以毫秒为单位)。 |
状态 |
只读 |
当前报告状态。 |
示例
以下示例代码演示如何在 HTML 代码中创建此对象。
<object id="civicfactory"
classid="clsid:2A11F42C-3E81-4ad4-9CBE-45579D89671A"
type="application/x-oleobject">
</object>
以下示例代码演示如何使用 Windows 脚本主机在 JScript 中创建此对象。
var civicfactory = WScript.CreateObject("LocationDisp.CivicAddressReportFactory");
以下示例代码演示如何使用 Windows 脚本主机在 VBScript 中创建此对象。
Dim civicfactory
Set civicfactory = WScript.CreateObject("LocationDisp.CivicAddressReportFactory")
要求
要求 | 值 |
---|---|
最低受支持的客户端 |
Windows 7 [仅限桌面应用] |
最低受支持的服务器 |
无受支持的版本 |