softtouch 9 Posted April 25, 2022 Is there any way to detect that the webview2 runtime is installed on the target system? Share this post Link to post
Lajos Juhász 293 Posted April 25, 2022 You can inspect the registry as documented here: https://docs.microsoft.com/en-us/microsoft-edge/webview2/concepts/distribution#detect-if-a-suitable-webview2-runtime-is-already-installed 1 Share this post Link to post
softtouch 9 Posted April 25, 2022 3 hours ago, Lajos Juhász said: You can inspect the registry as documented here: https://docs.microsoft.com/en-us/microsoft-edge/webview2/concepts/distribution#detect-if-a-suitable-webview2-runtime-is-already-installed Thanks, I did not see that. That seems to work. Share this post Link to post
KodeZwerg 54 Posted February 1, 2023 I did asked myself today the same question and did made a different approach and would like to know what you think about it? On the form with the TWebBrowser that has its SelectedEngine property set to "EdgeIfAvailable" I put in FormShow event: WebBrowser.Navigate('about:blank'); For the WebBrowser I did created an Event for "OnNavigateBefore2" with the following content: if string(URL) = string('about:blank') then if WebBrowser.ActiveEngine <> Edge then begin // here I let my form display a message that Edge Runtime is missing and a button to open the official download site end; For me it worked and now I searched for other solutions and found this thread. (I was aware of the Registry Key but that does not ensure if user might has deleted the WebView2Loader.dll...) Share this post Link to post
Der schöne Günther 316 Posted February 2, 2023 From my experience, this is sufficient: TWebBrowserHelper = class helper for TWebBrowser function getIsUsingEdge(): Boolean; end; function TWebBrowserHelper.getIsUsingEdge(): Boolean; begin Result := Assigned(GetEdgeInterface()); end; Share this post Link to post