WebView.SendCommand
-------------------

Executes a command on Windows IE.

| Component | Version | macOS | Windows | Linux | Server | iOS SDK |
|---|---|---|---|---|---|---|
| [WebView](component_WebView.md) | [7.3](newinversion73.md) | ❌ No | ✅ Yes | ❌ No | ❌ No | ❌ No |

MBS( "WebView.SendCommand"; WebViewerRef; CommandID ) 

**MBS**( **"WebView.SendCommand";** /\* Executes a command on Windows IE. \*/  
**$WebViewerRef**; /\* Either the Web Viewer Object Name or the Web Viewer ID as returned by "[WebView.FindByName](WebViewFindByName.md)" function. \*/   
**$CommandID**) /\* The command ID to send.e.g. 93 \*/ 

### Parameters

| Parameter | Description | Example |
|---|---|---|
| WebViewerRef | Either the Web Viewer Object Name or the Web Viewer ID as returned by "[WebView.FindByName](WebViewFindByName.md)" function. |  |
| CommandID | The command ID to send. | 93 |

### Result

Returns OK or error.

### Description

Executes a command on Windows IE.  
This is to send command message to webbrowser control.  
  
See identifiers here:  
<https://msdn.microsoft.com/en-us/library/aa741315(v=vs.85).aspx>  
### Examples

Print:

 MBS ( "Webview.[SendCommand](SendCommand.md)"; "web"; 93)  
View source code:

 MBS ( "Webview.[SendCommand](SendCommand.md)"; "web"; 2139)  
### See also

- [WebView.ExecCommand](WebViewExecCommand.md)
- [WebView.FindByName](WebViewFindByName.md)

### Release notes

- **Version 7.3**
    - Added [Webview.SendCommand](http://www.mbsplugins.eu/WebviewSendCommand.shtml) and [Webview.ExecCommand](http://www.mbsplugins.eu/WebviewExecCommand.shtml).

### Example Databases

- [WebViewer/Windows only/WebViewer Messages on Windows](https://www.mbsplugins.eu/MBS-FileMaker-Plugin-Examples/WebViewer/Windows%20only/WebViewer%20Messages%20on%20Windows.shtml#1Button55.0000000900.000000078.00000001015.0000000LayoutObjectAnchor_)

### Blog Entries

- [MBS FileMaker Plugin, version 7.3pr1](https://www.mbsplugins.de/archive/2017-06-05/MBS_FileMaker_Plugin_version_7/monkeybreadsoftware_blog_filemaker)

This function checks for a license.

Created 31st May 2017 , last changed 13th May 2021

  
[WebView.SelectedText](WebViewSelectedText.md) - [WebView.SetAllowsLinkPreview](WebViewSetAllowsLinkPreview.md)

[HTML Version](WebViewSendCommand.shtml)