Welcome to the Treehouse Community

Want to collaborate on code errors? Have bugs you need feedback on? Looking for an extra set of eyes on your latest project? Get support with fellow developers, designers, and programmers of all backgrounds and skill levels here with the Treehouse Community! While you're at it, check out some resources Treehouse students have shared here.

Looking to learn something new?

Treehouse offers a seven day free trial for new students. Get access to thousands of hours of content and join thousands of Treehouse students and alumni in the community today.

Start your free trial

C# C# Objects Inheritance Throwing Exceptions

The application crashes right after saying that map location is not on the map

All the code compiles correctly and I get the same warning about the variable not being assigned then I get the message that I wrote "That map location is not on the map!" I see the message for a split second before the console clears Why?

Steven Parker
Steven Parker
231,271 Points

Even better, make a snapshot of your workspace and post the link to it here.

Matthew Cushing
Matthew Cushing
12,048 Points

Bit late but I'm assuming you're not using TeamTreehouse Workspaces but rather using something like Visual Studio correct? I also had the issue of my console window closing immediately. In Visual Studio you can keep it open by either running it through debug mode or pressing "Start without debugging" (Ctrl + F5)

1 Answer