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 trialJason Storm
6,288 PointsEntity Framework Basics: When I run the app it does not write line the series title.
When I add a break point it looks like it skips the context.ComicBooks.Add(new ComicBook() section. When I first ran the program it did not write the title, so i added a break, stepped into, and it worked. now after i deleted the database in a previous vid it will not step into this part where it adds the title. it will not create a new database in the sqllocaldb explorer either.
Jason Storm
6,288 PointsThere is a lot of code. I could not wait, so even though it does not run properly I am moving forward with the lesson. It is just not creating the database. My code is the same as the lesson code. So there is something else not permitting the database to be created. I can even start with one of the sln files from the downloaded set and it will not create the database within VS. So this is probably not a code issue.
I'll get through the course. I just figured I would not have been the only one to have this issue.
K Cleveland
21,839 PointsDo you have localDB installed? To check, open your command prompt and type: sqllocaldb. What does it say?
4 Answers
Hamza Qaisrani
1,161 PointsI would suggest the same as Keaunna.
However I was also having the same issue with localDB and SQL server installed.
I then realised that once I run the console app. I had to wait for a few seconds (5-10), before it displayed the title.
K Cleveland
21,839 PointsYes @ Hamza, that happened to me as well. :)
Jason Storm
6,288 PointsYES, Hamza is correct. I have localDB and SQl server installed. I just waited over 10 seconds and it created the database and ran like it should.
THANKS Hamza Qaisrani!
Hamza Qaisrani
1,161 PointsAwesome! Glad to hear Jason!
Alec Meyer
6,303 PointsLike others have said, it takes a while. Also make sure you don't have the extra '\' if you are using the app.config method.
dk13
10,541 PointsThanks for the tip! It helped me! However, I would also like to add that I did not see the database appear in the databases folder inside SQL Server Object Explorer because I failed to REFRESH the screen! (not proud of that one...) Hope this helps someone...
Hamza Qaisrani
1,161 PointsHamza Qaisrani
1,161 PointsCould you please post your code so that it's easier to analyze and find the bug.