Wrox Programmer Forums
| Search | Today's Posts | Mark Forums Read
BOOK: C# 5.0 Programmer's Reference
This is the forum to discuss the Wrox book C# 5.0 Programmer's Reference by Rod Stephens; ISBN: 978-1-118-84728-2
Welcome to the p2p.wrox.com Forums.

You are currently viewing the BOOK: C# 5.0 Programmer's Reference 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
  #1 (permalink)  
Old October 5th, 2015, 04:54 PM
Authorized User
Points: 45, Level: 1
Points: 45, Level: 1 Points: 45, Level: 1 Points: 45, Level: 1
Activity: 0%
Activity: 0% Activity: 0% Activity: 0%
 
Join Date: Jan 2010
Posts: 10
Thanks: 0
Thanked 1 Time in 1 Post
Default Chapter 3 Errata

Page 49

Exercise number 4, in the second set of exercises, refers to the form button as setBackgroundButton, but it should actually be setBackgroundProperty to match the Name given in Exercise 2 on page 48.
  #2 (permalink)  
Old October 6th, 2015, 11:43 AM
Rod Stephens's Avatar
Wrox Author
Points: 3,166, Level: 23
Points: 3,166, Level: 23 Points: 3,166, Level: 23 Points: 3,166, Level: 23
Activity: 0%
Activity: 0% Activity: 0% Activity: 0%
 
Join Date: Jan 2006
Location: , , .
Posts: 647
Thanks: 2
Thanked 96 Times in 95 Posts
Default

Sorry about that. You're right that the names should match.

Microsoft's preferred naming convention says the name should end with the name of the control, so this should probably be setBackgroundButton and step 2 off the instructions should be corrected. But really it doesn't matter as long as they agree.
__________________
Rod

Rod Stephens, Microsoft MVP

Essential Algorithms: A Practical Approach to Computer Algorithms

(Please post reviews at Amazon or wherever you shop!)
  #3 (permalink)  
Old October 6th, 2015, 11:46 AM
Authorized User
Points: 45, Level: 1
Points: 45, Level: 1 Points: 45, Level: 1 Points: 45, Level: 1
Activity: 0%
Activity: 0% Activity: 0% Activity: 0%
 
Join Date: Jan 2010
Posts: 10
Thanks: 0
Thanked 1 Time in 1 Post
Default

Yeah, totally. The names just need to match is all. Thank a lot for informing me about Microsoft's recommended naming conventions, and for writing this excellent book.
  #4 (permalink)  
Old October 6th, 2015, 11:58 AM
Rod Stephens's Avatar
Wrox Author
Points: 3,166, Level: 23
Points: 3,166, Level: 23 Points: 3,166, Level: 23 Points: 3,166, Level: 23
Activity: 0%
Activity: 0% Activity: 0% Activity: 0%
 
Join Date: Jan 2006
Location: , , .
Posts: 647
Thanks: 2
Thanked 96 Times in 95 Posts
Default

Yeah their preferred convention is purposeControlType as in setBackgroundButton. Kind of silly considering how dead-set they are against using a control name prefix as in btnSetBackground.

Some developers argue that you should leave off the control entirely because it shouldn't matter what kind of control it is. For example, it shouldn't matter whether setBackground is a button, menu item, or something else. But then what do you do if you want to have a menu and a button?

It doesn't really matter as long as you're consistent.

I'm glad you like the book. Post a review when you have a chance!
__________________
Rod

Rod Stephens, Microsoft MVP

Essential Algorithms: A Practical Approach to Computer Algorithms

(Please post reviews at Amazon or wherever you shop!)


Similar Threads
Thread Thread Starter Forum Replies Last Post
Errata on question 2 in chapter 2 rg703 BOOK: MCSD Certification Toolkit (Exam 70-483): Programming in C# 3 October 8th, 2013 03:16 AM
Errata on Chapter 3 jack_cox BOOK: Professional iOS Network Programming: Connecting the Enterprise to the iPhone and iPad 0 November 8th, 2012 11:30 AM
Chapter 7 ScreenRotations Errata FrankNatoli BOOK: Beginning iOS 4 Application Development 0 June 20th, 2011 09:30 PM
Chapter 4 errata notig BOOK: Beginning Visual C# 2010 1 September 23rd, 2010 10:27 AM
Chapter 5 Errata rogerj BOOK: Professional ADO.NET 3.5 with LINQ and the Entity Framework ISBN: 978-0-470-22988-0 0 February 21st, 2009 04:53 PM





Powered by vBulletin®
Copyright ©2000 - 2020, Jelsoft Enterprises Ltd.
Copyright (c) 2020 John Wiley & Sons, Inc.