Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

RemoveAsync method from ReferenceCollection throws System.AccessViolationException #409

Open
anton-gabriel opened this issue Jan 14, 2023 · 0 comments

Comments

@anton-gabriel
Copy link

The RemoveAsync method from Community.VisualStudio.Toolkit.ReferenceCollection throws a System.AccessViolationException when used.

Package Version
Community.VisualStudio.Toolkit.17 version 17.0.486

Visual Studio version
Visual Studio 2022

Target Framework
.NET Framework 4.8

Steps to Reproduce
I used the example provided by @reduckted in this page: #180. More precisely the following lines of code:

Project project = await VS.Solutions.GetActiveProjectAsync();
await project.References.RemoveAsync(project.References.OfType<ProjectReference>().ToArray());

Screenshots
image

Please let me know if you need any more information to reproduce the issue.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant