次の方法で共有


IZoneIdentifier2 interface

Provides methods for including metadata about which Store app was the last to write to a file, as well as a hint provided by the app as to what the trust level should be.

Members

The IZoneIdentifier2 interface inherits from the IUnknown interface. IZoneIdentifier2 also has these types of members:

  • Methods

Methods

The IZoneIdentifier2 interface has these methods.

Method Description
GetAppDefinedZoneId

Gets the app-defined zone ID set by the last writer.

GetLastWriterPackageFamilyName

Gets the LastWriterPackageFamilyName for the last Store App to write the file.

RemoveAppDefinedZoneId

Removes the AppDefinedZoneId, effectively resetting it to the system default.

RemoveLastWriterPackageFamilyName

Removes the LastWriterPackageFamilyName from the Zone.Identifier alternate data stream.

SetAppDefinedZoneId

Sets AppDefinedZoneId to the ZoneId hint specified by the app. An app can update this field only if the file is open for read/write access; this will also update the LastWriterPackageFamilyName.

SetLastWriterPackageFamilyName

Sets the LastWriterPackageFamilyName of the last Store App to write the file. If the existing last writer is different from the current writer, AppDefinedZoneId is cleared.

 

Remarks

Zone.Identifier alternate data stream format

This interface reads and writes to the Zone.Identifier alternate data stream. The format of the alternative data stream is:

[ZoneTransfer]

ZoneId=3

LastWriterPackageFamilyName=Microsoft.Office.OneNote_8wekyb3d8bbwe

AppDefinedZoneId=0

Requirements

Minimum supported client

Windows 10

Minimum supported server

Windows Server 2016

Header

Urlmon.h

IDL

Urlmon.idl

DLL

Urlmon.dll