<xml> </xml>

SOLIDWORKS PDM Professional API Help | Send Feedback
BrowseForFile Method (IEdmVault5)
See Also Example

Collapse All Expand All Language Filter: All Language Filter: Multiple Language Filter: Visual Basic Language Filter: C# Language Filter: C++/CLI

EPDM.Interop.epdm Namespace > IEdmVault5 Interface : BrowseForFile Method (IEdmVault5)

Visual Basic
C#
C++/CLI

hParentWnd
  Parent window handle

lEdmBrowseFlags
  Optional combination of EdmBrowseFlag bits

bsFilter
  Optional filter string that limits the types of files displayed in the dialog box (see Remarks)

bsDefaultExtension
  Optional default file extension to append if the user does not specify an extension

bsDefaultFileName
  Optional default file name to display in the file name field of the dialog box

bsDefaultFolder
  Optional path to the folder on which the dialog box should initially open

bsCaption
  Optional caption for the dialog box

Displays an Open or Save As dialog box in which the user can click one or more files.

# Syntax

Visual Basic |
--- | ---

    Function BrowseForFile( _
       ByVal hParentWnd As System.Integer, _
       Optional ByVal lEdmBrowseFlags As System.Integer, _
       Optional ByVal bsFilter As System.String, _
       Optional ByVal bsDefaultExtension As System.String, _
       Optional ByVal bsDefaultFileName As System.String, _
       Optional ByVal bsDefaultFolder As System.String, _
       Optional ByVal bsCaption As System.String _
    ) As EdmStrLst5

C# |
--- | ---

    EdmStrLst5 BrowseForFile(
       System.int hParentWnd,
       System.int lEdmBrowseFlags,
       System.string bsFilter,
       System.string bsDefaultExtension,
       System.string bsDefaultFileName,
       System.string bsDefaultFolder,
       System.string bsCaption
    )

C++/CLI |
--- | ---

    EdmStrLst5^ BrowseForFile(
    &   System.int hParentWnd,
    &   System.int lEdmBrowseFlags,
    &   System.String^ bsFilter,
    &   System.String^ bsDefaultExtension,
    &   System.String^ bsDefaultFileName,
    &   System.String^ bsDefaultFolder,
    &   System.String^ bsCaption
    )

#### Parameters

hParentWnd
  Parent window handle
lEdmBrowseFlags
  Optional combination of EdmBrowseFlag bits
bsFilter
  Optional filter string that limits the types of files displayed in the dialog box (see Remarks)
bsDefaultExtension
  Optional default file extension to append if the user does not specify an extension
bsDefaultFileName
  Optional default file name to display in the file name field of the dialog box
bsDefaultFolder
  Optional path to the folder on which the dialog box should initially open
bsCaption
  Optional caption for the dialog box

#### Return Value

IEdmStrLst5; list of paths to multi-selected files; Null if the user clicks Cancel (see Remarks)

# Example

Set Initial Revision (VB.NET)
Set Initial Revision (C#)
Access Check-in Flags in Check out Dialog (VB.NET)
Access Check-in Flags in Check out Dialog (C#)
Prevent Admin from Checking In File (C#)
Prevent Admin from Checking In File (VB.NET)

# Remarks

If bsFilter is not empty, it contains the options for the Files of type combobox dropdown in the dialog box. Each option consists of a pair of substrings, where the first substring is the description that appears in the combobox dropdown:

> All Image Files (*.JPG,*.BMP)

and the second substring consists of one or more extension filters delimited by semicolons:

> *.JPG;*.BMP

The substrings are separated by a vertical bar, |, and the entire string is terminated with double vertical bars, ||.

For example, to give the combobox dropdown four options, including JPG and BMP file filters, specify bsFilter with the following string (without quotes):

"All Image Files (*.JPG,*.BMP)|*.JPG;*.BMP|JPEG-Files (*.JPG)|*.JPG|BMP-Files (*.BMP)|*.BMP|All Files (*.*)|*.*||"

Return codes:

- S_OK: The method successfully executed.

# See Also

####

IEdmVault5 Interface
IEdmVault5 Members
IEdmVault5::BrowseForFolder Method ()

# Availability

SOLIDWORKS PDM Professional Version 5.2