---
title: "webView(_:runOpenPanelForFileButtonWith:allowMultipleFiles:)"
framework: webkit
role: symbol
role_heading: Instance Method
path: "webkit/webuidelegate/webview(_:runopenpanelforfilebuttonwith:allowmultiplefiles:)"
---

# webView(_:runOpenPanelForFileButtonWith:allowMultipleFiles:)

Displays an open panel for a file input control.

## Declaration

```swift
optional func webView(_ sender: WebView!, runOpenPanelForFileButtonWith resultListener: (any WebOpenPanelResultListener)!, allowMultipleFiles: Bool)
```

## Parameters

- `sender`: The web view that sent the message.
- `resultListener`: See the doc://com.apple.webkit/documentation/WebKit/WebOpenPanelResultListener protocol for how to set these values.
- `allowMultipleFiles`: If doc://com.apple.documentation/documentation/Swift/true, the open panel should allow multiple files to be selected; otherwise, it should not.

## See Also

### Opening Panels

- [webView(_:runJavaScriptAlertPanelWithMessage:initiatedBy:)](webkit/webuidelegate/webview(_:runjavascriptalertpanelwithmessage:initiatedby:).md)
- [webView(_:runJavaScriptConfirmPanelWithMessage:initiatedBy:)](webkit/webuidelegate/webview(_:runjavascriptconfirmpanelwithmessage:initiatedby:).md)
- [webView(_:runJavaScriptTextInputPanelWithPrompt:defaultText:initiatedBy:)](webkit/webuidelegate/webview(_:runjavascripttextinputpanelwithprompt:defaulttext:initiatedby:).md)
- [webView(_:runOpenPanelForFileButtonWith:)](webkit/webuidelegate/webview(_:runopenpanelforfilebuttonwith:).md)
- [webView(_:runBeforeUnloadConfirmPanelWithMessage:initiatedBy:)](webkit/webuidelegate/webview(_:runbeforeunloadconfirmpanelwithmessage:initiatedby:).md)
