VCOM:VectorWorks:Filing:IFolderIdentifier::GetParentFolder

From Vectorworks Developer
Jump to navigation Jump to search

.SDK|SDK ..SDK:Types|SDK Types ..VCOM:VCOM (Vectorworks Component Object Model)|VCOM Basics ..VCOM:Class Reference|VCOM Class Reference

Description

namespace VectorWorks::Filing

Member of VCOM:VectorWorks:Filing:IFolderIdentifier

virtual VCOMError VCOM_CALLTYPE GetParentFolder(
IFolderIdentifier** ppOutParentFolderID) = 0;

Parameters

ppOutParentFolderID IFolderIdentifier* Output parameter. Return new instance of the IFolderIdentifier interface containing the parent folder of this one.

Return Value

Uses standard VCOM Error Reporting.

Return value meaning:

kVCOMError_NotInitialized Bad VCOM instance used to call the fuction.
kVCOMError_Failed The function failed. That may be because there is no path set to the instance.

Remarks

The funtion releases the passed interface if it has been queried, and queries it again.

So it is good advice not to query if you dont need to before this call. See sample.

Example

Sample uses VCOMPtr template class to simplify the use of VCOM:VCOM (VectorWorks Component Object Model) instances.

Note that the default VCOMPtr constructor is used.

// create NULL interface instance -- does not query here
VCOMPtr< IFolderIdentifier >   pParentFolder; 

// this call will query the instance
pFolder->GetParentFolder( & pParentFolder );

See Also

VCOM:VectorWorks:Filing:IFolderIdentifier

[[VCOM:VectorWorks:Filing:IFolderIdentifier]]