MonoGame project Exited with code 1 with MSB3073 Error

I’ve been stuck on this issue for a bit and I’m a little embarrassed because I’m pretty sure I fixed it before on my main workstation. Now that I am trying to run this project on anther workstation copying the project from a thumb drive into the repos section the project won’t compile. I’ve added the quotes around the mgcpath in the target file, i dont believe i have a space in my username, and I also tried uninstalling the packages reinstalling. I would definitely love to understand this issue in greater detail beyond what to do to fix the issue, because I’m sure you monogame

experts are tired of answering this one.

Did you disable NUGET?

1 Like

Try opening the content.mgcb file in the MGCB Editor and do a rebuild. If everything is ok. Then rebuild your solution.

1 Like

If we look closely at your error messages your .mgcb file expects to find the image shinobi.png, but can’t. Probably because it doesn’t exist as we can see from the project tree in visual studio, shinobi3.png however does exist.

Solution should be to simply open your Content.mgcb and update the files so that they are correct I guess, make sure the shinobi.png exists if it should, remove it from the .mgcb if it shouldn’t.


Is this a case of adding the xnb and forgetting the png?

I thought the xnb embeds the png though?

just curious…

1 Like

I’m pretty sure the xnb just takes any image file and transforms it to the format it deems appropriate for the target platform, if it also had to embed the origin file it would waste a lot of space on the end users machine.

Even so, the file shinobi.xnb doesn’t exist, so it’s not a case of adding the xnb, it’s the opposite if anything

I know that but have you missed his dependencies missing too?

I think there is some exterior file access blocking going on…


Oh this is a DesktopGL project…

1 Like

Every single one of you are amazing. THank YOU FOR HELPING ME FIXTHIS. CHEERS AND HAPPY CODING!!!

1 Like

How did you fix it?

Would help future trespassers’

All I had to do was rebuild the mgcb content. Not sure if there was an easier way but i copied the missing files to the desktop, excluded the broken files in the mgcb editor, and rebuilt the content.

1 Like