SOLIDWORKS PDM Professional API Help Send Feedback
DeleteFile Method (IEdmFolder5)
See Also  Example
EPDM.Interop.epdm Namespace > IEdmFolder5 Interface : DeleteFile Method (IEdmFolder5)


lParentWnd
Parent window handle
lFileID
ID of file to delete
bRemoveLocalCopy
Optionally, true to erase the local copy of the file, false to not; default is true
Deletes a file having the specified ID from this folder.

Syntax

Visual Basic 
Sub DeleteFile( _
   ByVal lParentWnd As System.Integer, _
   ByVal lFileID As System.Integer, _
   Optional ByVal bRemoveLocalCopy As System.Boolean _
) 
C# 
void DeleteFile( 
   System.int lParentWnd,
   System.int lFileID,
   System.bool bRemoveLocalCopy
)
C++/CLI 
void DeleteFile( 
&   System.int lParentWnd,
&   System.int lFileID,
&   System.bool bRemoveLocalCopy
) 

Parameters

lParentWnd
Parent window handle
lFileID
ID of file to delete
bRemoveLocalCopy
Optionally, true to erase the local copy of the file, false to not; default is true

Example

Remarks

If the specified file is shared to other folders, it is deleted only from this folder.

Return codes:

  • S_OK: The method successfully executed.
  • E_EDM_FILE_NOT_FOUND: The file ID is invalid.
  • E_EDM_OPERATION_REFUSED_BY_PLUGIN: The operation is not permitted by one of the installed EdmCmdData.EdmCmd_PreDelete hooks.
  • E_EDM_LOCKED_BY_ANOTHER_USER: The file cannot be deleted since it is checked out by another user.
  • E_EDM_PERMISSION_DENIED: The user lacks permission to delete the file.
 

See Also

Availability

SOLIDWORKS PDM Professional Version 5.2