The Author Online Book Forums are Moving

The Author Online Book Forums will soon redirect to Manning's liveBook and liveVideo. All book forum content will migrate to liveBook's discussion forum and all video forum content will migrate to liveVideo. Log in to liveBook or liveVideo with your Manning credentials to join the discussion!

Thank you for your engagement in the AoF over the years! We look forward to offering you a more enhanced forum experience.

niblettes (1) [Avatar] Offline
#1
For the advanced grid sample in chapter 7 I copy/pasted the code as it is in the book. The results are a page that displays the all the right widgets but doesn't request any data.

I then downloaded the code, saved it, and tried it. This code works perfectly, displaying everything correctly.

I compared the two sets of code, and sure enough they aren't the same. Most troubling is the fact that the differences are not typos.

For example:
PDF page 164 says "Next you pass a url property, which is one of the shortcuts we’re using. Because you pass this property, the Store class will use it to instantiate a Proxy to fetch data," Judging by the results this is not true. The PDF code does this and doesn't work. The downloadable code does not do this and it does work. To make the PDF code work you have to explicitly set the STP.

And for another example:
PDF page 164 says: "When I build applications, I always configure objects instead of strings because I like to think of the code as self-documenting." But the downloadable code starting on line 21 uses a string for RecordFiles where the book uses objects. Why waste a paragraph telling readers why one way is better and then do it another way in the downloadable code? Furthermore this becomes an annoying red herring when trying to figure out why the PDF code doesn't work.

Did anyone do a code review before publication?
jesus.garcia (463) [Avatar] Offline
#2
Re: Errata - Code in PDF and downloadable code don't match chapter 7
I apologize for having that one slip through the cracks. To be honest, I never copy from the PDF when reading books. Though, it's no excuse to have a difference like that.