CompositeGeniePlace
- Last UpdatedJul 13, 2023
- 2 minute read
Places a Composite Genie at the specified co-ordinates on the active page.
Note: This function does not support implicit value type casting.
Syntax
CompositeGeniePlace(templateID, KeyValuePair, nXPos, nYPos)
templateID
Visual template ID of the Composite Genie template. This can be found in the root node attribute "Guid" of the Composite Genie's XML template.
KeyValuePair
This is a special key value pair that comes from the Graphics Builder. Note that this is different from the .NET key value pair.
nXPos
The horizontal offset position on the page where you want to place the Composite Genie.
nYPos
The vertical offset position on the page where you want to place the Composite Genie.
HResult
The HResult is retrieved from the calling function's exception-handling mechanism. For example, if the calling function is .NET-based, a COM exception such as System.Runtime.InteropServices.COMException will be thrown if the HRESULT is not S_OK.
The possible values for HResult include:
-
S_OK indicates success
-
E_FAIL indicates an error condition in the system. For example, the Composite Genie template may have a syntactical error, or if one of the Content Item Genies is missing.
-
E_INVALIDARG indicates that one of the arguments is incorrect. For example, one of the key names in the KeyValuePair does not exist or one of the value types does not match the parameter definition.
-
E_ABORT is returned if you attempt to place the Composite Genie at an invalid location on the page.
Troubleshooting
If you encounter E_FAIL, it is recommended that you manually paste the Composite Genie on the page.
If you encounter E_INVALIDARG, check that the parameter names exist and parameter values match the type described in the visual template.