setFileTypeIndex method

void setFileTypeIndex(
  1. int iFileType
)

Sets the file type that appears as selected in the dialog.

Throws a WindowsException on failure.

To learn more, see learn.microsoft.com/windows/win32/api/shobjidl_core/nf-shobjidl_core-ifiledialog-setfiletypeindex.

Implementation

@pragma('vm:prefer-inline')
void setFileTypeIndex(int iFileType) {
  final hr$ = HRESULT(_SetFileTypeIndexFn(ptr, iFileType));
  if (hr$.isError) throw WindowsException(hr$);
}