Skip to content

Comments

fix(vcproject): use dynamic binding to avoid assembly load failure#34

Merged
CalvinAllen merged 1 commit intomainfrom
fix/vcproject/dynamic-loading-v2
Feb 13, 2026
Merged

fix(vcproject): use dynamic binding to avoid assembly load failure#34
CalvinAllen merged 1 commit intomainfrom
fix/vcproject/dynamic-loading-v2

Conversation

@CalvinAllen
Copy link
Collaborator

Summary

  • Removes compile-time reference to Microsoft.VisualStudio.VCProjectEngine and replaces it with dynamic late binding
  • The previous fix (fix(vsix): include VCProjectEngine assembly in VSIX package #33) bundled the assembly in the VSIX, but users still reported the same FileNotFoundException on both VS 2022 and VS 2026
  • By using dynamic, the VCProjectEngine assembly is only resolved at runtime when actually handling a C++ project, preventing the error for all other project types

Root Cause

The JIT compiler needed to resolve VCProject and VCConfiguration types when compiling OpenProjectBinFolder, even for non-C++ projects. This caused an assembly load failure for users without the C++ workload installed, regardless of whether the assembly was bundled in the VSIX.

Test plan

  • Open a C#/VB.NET/F# project in VS 2022 and use "Open Bin Folder" — should work without errors
  • Open a C++ project in VS 2022 (with C++ workload) and use "Open Bin Folder" — should work correctly
  • Verify on VS 2026

Resolves #32

… load failure

Replace compile-time VCProjectEngine reference with dynamic late binding
so the assembly is only resolved at runtime for C++ projects, preventing
FileNotFoundException for users without the C++ workload installed.
@CalvinAllen CalvinAllen changed the title fix(vcproject): use dynamic binding to avoid VCProjectEngine assembly load failure fix(vcproject): use dynamic binding to avoid assembly load failure Feb 13, 2026
@CalvinAllen CalvinAllen merged commit 771d576 into main Feb 13, 2026
2 of 3 checks passed
@CalvinAllen CalvinAllen deleted the fix/vcproject/dynamic-loading-v2 branch February 13, 2026 14:28
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Development

Successfully merging this pull request may close these issues.

Cannot open bin folder: missing assembly?

1 participant