MicrosoftEdge / MicrosoftEdge/WebView2Feedback
Cannot load WebView2Loader.dll in Excel VSTO Add-In
@champnic is already working on this.
Since Apr 6, 2022.
- Dominant language
- PowerShell
- Stars
- 526
- Forks
- 67
- PR merge metrics
- No merged PRs in 30d
Description
Description
I'm building a VSTO Add-In using Visual Studio 2019 on Windows 10.
After adding the ribbon, windows form and the WebView2 user control I get an error message saying that said DLL cannot be found.
Version
SDK: 1.0.1189-prerelease
Runtime: Evergreen 99.0.1150.55
Framework: WinForms
OS: Win10 21H2 Build 19044.1586
Repro Steps
- open Visual Studio 2019
- create new project
- search for VSTO
- select Excel-VSTP-Add-In
- name it excel-vsto-webview
- add a Ribbon (XML) via insert new element
- add custom ribbon code (XML) to show button near File->Save As
- initialize ribbon in addin class
- OK: pressing F5, creating empty workbook, clicking File, Save,
My custom task, My Button results in a message box popup - add a Windows Form via insert menu
- show form instead of message box in ribbon code (button click)
- OK: pressing F5, creating empty workbook, clicking File, Save,
My custom task, My Button results in an empty Form window popping up - add WebView2 NuGet package via package manager, version 1.0.1189-prerelease
- drag WebView2 Windows Forms control into Form1 using the designer
- OK: pressing F5, creating empty workbook, clicking File, Save,
My custom task, My Button results in an empty Form window popping up - adding webview2 init code from @cgeier https://github.com/MicrosoftEdge/WebView2Feedback/issues/187
- NOK: pressing F5, creating empty workbook, clicking File, Save,
My custom task, My Button results in an empty Form window popping up
plus error message, telling me it cant find a dll called WebView2Loader.dll
Screenshots
Additional context
Repository containing exactly what is mentioned in repro steps: https://github.com/FROGGS/excel-vsto-webview
Contributor guide
No contributing guide indexed for this repository
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Assessment
This issue has not been assessed yet.