error: NU1100: Unable to resolve 'MicrosoftOfficeCore (>= 15.0.0)' for 'net5.0'

asked4 years ago
last updated3 years ago
viewed11.7k times
Up Vote22Down Vote

In Terminal of Visual Studio Code, when I try to run:

dotnet add package MicrosoftOfficeCore --version 15.0.0

I get the following error on Visual Studio Code terminal:

error: NU1100: Unable to resolve 'MicrosoftOfficeCore (>= 15.0.0)' for 'net5.0'
error: Package 'MicrosoftOfficeCore' is incompatible with 'all' frameworks in project

Do anyone have an idea?