Hide Table of Contents
BrowseForFile Method (IEdmVault5)

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


Visual Basic (Declaration) 
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
EdmStrLst5 BrowseForFile( 
   System.int hParentWnd,
   System.int lEdmBrowseFlags,
   System.string bsFilter,
   System.string bsDefaultExtension,
   System.string bsDefaultFileName,
   System.string bsDefaultFolder,
   System.string bsCaption
EdmStrLst5^ BrowseForFile( 
&   System.int hParentWnd,
&   System.int lEdmBrowseFlags,
&   System.String^ bsFilter,
&   System.String^ bsDefaultExtension,
&   System.String^ bsDefaultFileName,
&   System.String^ bsDefaultFolder,
&   System.String^ bsCaption


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

Return Value

IEdmStrLst5; list of paths to multi-selected files; Null if the user clicks Cancel (see 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:


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


SOLIDWORKS Enterprise PDM Version 5.2

Provide feedback on this topic

SOLIDWORKS welcomes your feedback concerning the presentation, accuracy, and thoroughness of the documentation. Use the form below to send your comments and suggestions about this topic directly to our documentation team. The documentation team cannot answer technical support questions. Click here for information about technical support.

* Required

Subject:   Feedback on Help Topics
Page:   BrowseForFile Method (IEdmVault5)
*   I acknowledge I have read and I hereby accept the privacy policy under which my Personal Data will be used by Dassault Systèmes

Print Topic

Select the scope of content to print:


We have detected you are using a browser version older than Internet Explorer 7. For optimized display, we suggest upgrading your browser to Internet Explorer 7 or newer.

 Never show this message again

Web Help Content Version: API Help (English only) 2015 SP05

To disable Web help from within SOLIDWORKS and use local help instead, click Help > Use SOLIDWORKS Web Help.

To report problems encountered with the Web help interface and search, contact your local support representative. To provide feedback on individual help topics, use the “Feedback on this topic” link on the individual topic page.