[SOLVED] Can't even compile new project.

Disclaimer: I’m new here. I don’t know if this is the exact right place to post this, but I’m down to be told where to go if it isn’t.

It’s honestly been a few years since I did any programming and I was never super involved, so please treat me like an idiot. I started a new MonoGame WIndows Project in Visual Studio and I went to build it right off the bat because why not. I was treated to this error…

1>------ Build started: Project: JibNinja, Configuration: Debug x86 ------
1>C:\Program Files (x86)\Microsoft Visual Studio\2017\Community\MSBuild\15.0\Bin\Microsoft.Common.CurrentVersion.targets(1111,5): error MSB3644: The reference assemblies for framework “.NETFramework,Version=v4.5” were not found. To resolve this, install the SDK or Targeting Pack for this framework version or retarget your application to a version of the framework for which you have the SDK or Targeting Pack installed. Note that assemblies will be resolved from the Global Assembly Cache (GAC) and will be used in place of reference assemblies. Therefore your assembly may not be correctly targeted for the framework you intend.
========== Build: 0 succeeded or up-to-date, 1 failed, 0 skipped ==========

I don’t know what I possibly could have done wrong. I re-downloaded the latest framework and SDK and what-not. (I think) I’m well aware of how weapons-grade-derp this post is, so please be nice. I really want to resolve this so I can get back to making dumb little game projects again.

Maybe double check youve installed 4.5? Reboot afterwards, and then right click on your project -> Properties -> Applicaton and make sure the target framework is still set to that ).

You can also click on the Target Framework drop down and select “Install other Frame works”/

4.5 is here:

https://www.microsoft.com/en-ca/download/details.aspx?id=30653
OR

IIRC it should have been installed with VS2017, so something may have gone wrong on the install too.

What Windows are you on? 4.5 comes as standard on 8.0/8.1 and up… Are you on Windows 7? (I always thought VS17 didn’t install on Windows 7)

Also when setting up your project, after you click create new project, look at the top to see if 4.5 is selected as well…

Also, hi and welcome to the forums, and remember, in programming, there are no stupid questions, we are all noobs at some point and at some things further down the line, so, don’t worry about sounding stupid, even last night I asked what I felt were daft questions, so don’t fret it…

Happy coding!

Hey guys, thanks. Turns out a reinstall of Visual Studio did the trick.

1 Like