Open red-swan opened 4 years ago
Hey. Let me have a look into this this week - most likely it's just that VS2017 and 2019 work slightly different in terms of NuGet than 2015 did and that there was a breaking change (at least, that's what it appears).
I don't even have 2015 installed anymore so I'll give this a go to see what's wrong - sorry about that!
No worries! Book's great. I await your investigation.
@red-swan can you pull the latest version and try again? I think it was just that the project was targetting an older version of .NET Framework (4.5) and it needed to be upgraded to a later version (4.7.2). It should work now.
I tried building the solution in VS2017 and VS2019. Building the F# Core project goes through smoothly. When I try to build the WpfClient project, I get the same error in both IDEs:
Severity Code Description Project File Line Suppression State
Error Unknown build error, 'Cannot resolve dependency to assembly 'FSharp.Core, Version=4.7.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a' because it has not been preloaded. When using the ReflectionOnly APIs, dependent assemblies must be pre-loaded or loaded on demand through the ReflectionOnlyAssemblyResolve event.' WpfClient
What version of VS2019 and .NET Framework do you have installed?
VS 2019 16.3.2 VS2017 15.9.16 Using this article I find that I have .NET 4.8 installed.
When I open the solution in, there's a yellow arrow on the FSharp.Core reference.
I edited Core.fsproj
to change FSharp.Core
's version to be 4.5.0.0 and then added a reference to that version in both projects and it compiled just fine. .NET makes no sense to me!
Upon opening
Capstone5.sln
file in the/src/code-listings/lesson-29
folder orsample-solution
subfolder in VIsual Studio 2017 or 2019, I get the following build error when trying to compile the solution.I'm not a .NET expert, so I don't know how to resolve this. Is there a fix for this?