 |
BOOK: Beginning ASP.NET 4 : in C# and VB
 | This is the forum to discuss the Wrox book Beginning ASP.NET 4: in C# and VB by Imar Spaanjaars; ISBN: 9780470502211 |
Welcome to the p2p.wrox.com Forums.
You are currently viewing the BOOK: Beginning ASP.NET 4 : in C# and VB section of the Wrox Programmer to Programmer discussions. This is a community of software programmers and website developers including Wrox book authors and readers. New member registration was closed in 2019. New posts were shut off and the site was archived into this static format as of October 1, 2020. If you require technical support for a Wrox book please contact http://hub.wiley.com
|
|
|
|
|

January 29th, 2014, 07:54 PM
|
|
Registered User
|
|
Join Date: Jan 2014
Posts: 6
Thanks: 3
Thanked 0 Times in 0 Posts
|
|
Chapter 14 PlanetWrox.edmx
I have been working through the beginners book and have come across a problem that I can't get past.
I am using VS2013 for this entire project.
Within the "Try it Out" on pages 501 and 502 I don't get the ability to change the Code generation strategy property from None to default in step 7. The property is disabled and set to "T4".
Subsequently if I delete the *.tt files as pointed out in step 8, I can't reference PlanetWroxModel at all in step 10 with the Imports statement.
Regards
Kim
|
|

January 30th, 2014, 04:53 PM
|
 |
Wrox Author
|
|
Join Date: Jun 2003
Posts: 17,089
Thanks: 80
Thanked 1,576 Times in 1,552 Posts
|
|
Hi Kim,
You may want to take a look here where Alan asked the same question: Ch 14 generating entity model
Cheers,
Imar
|
|

January 30th, 2014, 10:36 PM
|
|
Registered User
|
|
Join Date: Jan 2014
Posts: 6
Thanks: 3
Thanked 0 Times in 0 Posts
|
|
Hi Imar,
Thanks again for the quick reply.
I selected the entity framework version 6.0, unlike Alan. However I don't have the option to select other than "T4" in the code generation strategy property. This property is disabled.
How can I select entity framework 5.0, since I selected the "Don't show option" in step 4.
Regards
Kim
|
|

January 31st, 2014, 05:10 AM
|
 |
Wrox Author
|
|
Join Date: Jun 2003
Posts: 17,089
Thanks: 80
Thanked 1,576 Times in 1,552 Posts
|
|
Hi Kim,
>>How can I select entity framework 5.0, since I selected the "Don't show option" in step 4.
Not sure which option you're referring to. When I add an EDMX, I can choose between 5 and 6, but I see no checkbox to never ask the version again. Or do you mean the option about suppressing the security warning?
I think if you uninstall the EntityFramework (using the Package Manager Console with the command Uninstall-Packge EntityFramework) you should be able to add an EDMX again and pick version 5.
Hope this helps,
Imar
|
|
The Following User Says Thank You to Imar For This Useful Post:
|
|
|

February 24th, 2014, 12:33 AM
|
|
Registered User
|
|
Join Date: Jan 2014
Posts: 6
Thanks: 3
Thanked 0 Times in 0 Posts
|
|
Thanks Imar,
Just some additional notes, in version 2013 of VS for EDMX, the PlanteWroxEntities namespace must be different from the Entity Container name (Used PlanetWroxModel), and the Code Generation strategy has to be set to 'Legacy ObjectContext'.
Thus the imports for VB code is set to 'PlanetWroxModel' now all works fine.
Guess it must be difficult to continue to update your book for each version of VS if it changes each year.
Thanks Again
|
|

February 24th, 2014, 04:49 PM
|
 |
Wrox Author
|
|
Join Date: Jun 2003
Posts: 17,089
Thanks: 80
Thanked 1,576 Times in 1,552 Posts
|
|
>> Guess it must be difficult to continue to update your book for each version of VS if it changes each year.
The hardest part is supporting people that use non-matching versions of the book and VS, as sometimes it's hard to see what they do.
I just finished an update of my book for VS 2013 and ASP.NET 4.5.1. where all this gets addressed "the proper" way. No legacy context, targeting EF 6 and using Model Binding instead of the more or less obsolete Entity Data Source control.
Imar
|
|
The Following User Says Thank You to Imar For This Useful Post:
|
|
|

February 24th, 2014, 06:37 PM
|
|
Registered User
|
|
Join Date: Jan 2014
Posts: 6
Thanks: 3
Thanked 0 Times in 0 Posts
|
|
Hi Imar,
Would you be able to keep me informed as to when your update to your book will be available.
Kim
|
|

February 24th, 2014, 07:19 PM
|
 |
Wrox Author
|
|
Join Date: Jun 2003
Posts: 17,089
Thanks: 80
Thanked 1,576 Times in 1,552 Posts
|
|
Hi Kim,
Amazon says March 24, which is probably accurate: http://www.amazon.com/Beginning-ASP-...rds=spaanjaars
Imar
|
|
The Following User Says Thank You to Imar For This Useful Post:
|
|
|
 |
|