共用方式為


IXpsOMFontResourceCollection::GetByPartName 方法 (xpsobjectmodel.h)

藉由比對接口的元件名稱,從集合取得 IXpsOMFontResource 介面指標。

語法

HRESULT GetByPartName(
  [in]          IOpcPartUri        *partName,
  [out, retval] IXpsOMFontResource **part
);

參數

[in] partName

集合中要找到之 IXpsOMFontResource 介面的元件名稱。

[out, retval] part

具有相符元件名稱之 IXpsOMFontResource 介面的指標。 如果在集合中找不到相符的介面,則會傳回 NULL 指標。

傳回值

如果方法成功,它會傳回S_OK;否則會傳回 HRESULT 錯誤碼。

規格需求

需求
最低支援的用戶端 適用於 Windows Vista 的 Windows 7、Windows Vista SP2 和平臺更新 [傳統型應用程式 |UWP 應用程式]
最低支援的伺服器 Windows Server 2008 R2、Windows Server 2008 SP2 和 Platform Update for Windows Server 2008 [傳統型應用程式 |UWP 應用程式]
目標平台 Windows
標頭 xpsobjectmodel.h

另請參閱

IOpcPartUri

IXpsOMFontResource

IXpsOMFontResourceCollection

XML Paper Specification