DVARIANT.PutResourcemethod
Initializes the DVARIANT based on a string resource imbedded in an executable file.
Syntax
FUNCTION PutResource (BYVAL hinst AS HINSTANCE, BYVAL id AS UINT) AS HRESULT
Parameters
| Name | Description | |
|---|---|---|
hinst | The instance handle. | |
id | Integer identifier of the string to be loaded. |
Return value
If this function succeeds, it returns S_OK (0). Otherwise, it returns an HRESULT error code.
Description
Initializes the DVARIANT based on a string resource imbedded in an executable file.
Remarks
Creates a VT_BSTR variant. If the resource does not exist, this function initializes the VARIANT as VT_EMPTY and returns a failure code.
Reference
- Include file
DVARIANT.INC - Defined in AfxNova/DVARIANT.inc:1303
- Documented in COM/DVARIANT Class.md
- Topic: DVARIANT Class