GetTypeForDoc method
Retrieves the document type.
This method is intended for use with Visual Basic.
- Method
- short GetYpeForDoc(
- Parameters
- Index
- Specifies the zero-based index of a document within the document list of the active folder. If this value is less than zero, then the open document is used.
- pType
- Points to a variable to receive the document type of the specified document. The document type will be one of the document type values found in ARSOLEEX.H, such as ARS_OLE_DOC_TYPE_AFP.
- pExtension
- Points to a BSTR to receive the file extension of the document. This value is returned only if the document type is ARS_OLE_DOC_TYPE_USER_DEF.
- Description
- If the document type is ARS_OLE_DOC_TYPE_USER_DEF, then the file extension is also retrieved.
- Return Value
- Refer to return codes.
- See Also
- GetDocType method
The following example retrieves the document type for the
third item in the document list.
DIM rc As Integer
DIM type As Variant
DIM ext As String
.
.
.
rc = pArsCtrl->GetTypeForDoc(2, type, ext);
if rc <> ARS_OLE_RC_SUCCESS THEN
MsgBox "ERROR"
End
Endif
.
.
.