IPXS_PDFVariant::Arr_SetName Method
From PDF XChange PDF SDK
m (Automatic page editing by robot) |
|||
(One intermediate revision by one other user not shown) | |||
Line 3: | Line 3: | ||
{{#customTitle:IPXS_PDFVariant::Arr_SetName Method}} | {{#customTitle:IPXS_PDFVariant::Arr_SetName Method}} | ||
{{#parentPage:PXV:IPXS_PDFVariant#Methods|Arr_SetName|method}} | {{#parentPage:PXV:IPXS_PDFVariant#Methods|Arr_SetName|method}} | ||
− | |||
{{ToReview}} | {{ToReview}} | ||
− | + | Replace specified element of array with new variant with type <code>PVT_Name</code> and specified value. | |
== Syntax == | == Syntax == | ||
− | <pre class="brush:cpp;gutter:false">HRESULT Arr_SetName([in] ULONG | + | <pre class="brush:cpp;gutter:false">HRESULT Arr_SetName([in] ULONG nPos, |
− | [in] LPWSTR | + | [in] LPWSTR sVal);</pre> |
== Parameters == | == Parameters == | ||
− | ; | + | ;nPos |
− | :[in] | + | :[in] Specifies index of element to replace. If it is greater or equal to array size function will return <code>E_INVALIDARG</code>. |
− | ; | + | ;sVal |
− | :[in] | + | :[in] Pointer to null-terminated Unicode string, which will be converted to name value. |
+ | :Please note that this function has much lower performance than [[PXV:IPXS_PDFVariant_Arr_SetNameA|Arr_SetNameA]] because '''Unicode''' >> '''Raw data''' >> '''name''' conversion, so it is strongly not recommended to use it when set 'common' pdf names | ||
== Return Value == | == Return Value == |
Latest revision as of 06:20, 21 August 2015
Replace specified element of array with new variant with type PVT_Name
and specified value.
Syntax
HRESULT Arr_SetName([in] ULONG nPos, [in] LPWSTR sVal);
Parameters
- nPos
- [in] Specifies index of element to replace. If it is greater or equal to array size function will return
E_INVALIDARG
. - sVal
- [in] Pointer to null-terminated Unicode string, which will be converted to name value.
- Please note that this function has much lower performance than Arr_SetNameA because Unicode >> Raw data >> name conversion, so it is strongly not recommended to use it when set 'common' pdf names
Return Value
Returns S_OK if operation was successful or error code in other cases.