DBWDocumentFileType

<< Click to Display Table of Contents >>

Navigation:  Programming Mechworks PDM > DBWCommandShell > Library Reference > Document >

DBWDocumentFileType

Description

Detects if the document is of the type specified.

Syntax

Function DBWDocumentFileType(FullFileName, DBWorksType)

Parameters

FullFileName

is the entire (comprehensive of all directories) file name

DBWorksType

is the type of the current document

Return Values

TRUE

If the document belongs to the type specified in DocumentFileType.

Valid types recognized are:

'P' for parts

'A' for assemblies

'D' for drawings

'0' (zero) for projects

FALSE

otherwise

Example

if DBWDocumentFileType(FullFileName, DbWorksType) then
 msgbox "Ok! VALID type document"
else
 msgbox FullFileName & " is not a " & DbWorksType & " type document."
end if