Export (0) Print
Expand All

IFileDialog::GetFileName method

Retrieves the text currently entered in the dialog's File name edit box.

Syntax


HRESULT GetFileName(
  [out]  WCHAR **pszName
);

Parameters

pszName [out]

Type: WCHAR**

The address of a pointer to a buffer that, when this method returns successfully, receives the text.

Return value

Type: HRESULT

If this method succeeds, it returns S_OK. Otherwise, it returns an HRESULT error code.

Remarks

The text in the File name edit box does not necessarily reflect the item the user chose. To get the item the user chose, use IFileDialog::GetResult.

The calling application is responsible for releasing the retrieved buffer by using the CoTaskMemFree function.

Requirements

Minimum supported client

Windows Vista [desktop apps only]

Minimum supported server

Windows Server 2008 [desktop apps only]

Header

Shobjidl.h

IDL

Shobjidl.idl

 

 

Community Additions

ADD
Show:
© 2014 Microsoft