 |
BOOK: Beginning ASP.NET 3.5 : in C# and VB BOOK ISBN: 978-0-470-18759-3
 | This is the forum to discuss the Wrox book Beginning ASP.NET 3.5: In C# and VB by Imar Spaanjaars; ISBN: 9780470187593 |
|
Welcome to the p2p.wrox.com Forums.
You are currently viewing the BOOK: Beginning ASP.NET 3.5 : in C# and VB BOOK ISBN: 978-0-470-18759-3 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
|
|
|
|
|

July 6th, 2010, 01:13 AM
|
|
Friend of Wrox
|
|
Join Date: Jan 2004
Posts: 1,870
Thanks: 12
Thanked 20 Times in 20 Posts
|
|
Control ID value doesnt like leading integer
Hi there - my first post in this areea of the forum. Moving from classic ASP to this world is being made a whole heap easier with your book Imar. Starting out very basic its geting progressivley more enjoyable.
Please excuse me I am using VS 2010... Not that its a big issue but I am wondering why a control ID value can not have a leading integer. Up to Chapter 6 page 223 try it out step 1 (I did come accross this earlier in the book). The value '1stPreferedTheme' is rejected saying 'Property value is not valid' Why is this?
Thanking you
__________________
Wind is your friend
Matt
|
|

July 6th, 2010, 01:56 AM
|
 |
Wrox Author
|
|
Join Date: Jun 2003
Posts: 17,089
Thanks: 80
Thanked 1,576 Times in 1,552 Posts
|
|
Hi Matt,
Why it cannnot start with an integer I don't know. That's something that Visual Studio is enforcing. I guess the underlying language doesn't support it.
But in the book, the control doesn't start with an integer. That's an issue with the font in the book that makes it look like an integer unfortunately. The control starts with an l from List, not with a one from First.
You're not the first one to run into this (see errata: http://www.wrox.com/WileyCDA/WroxTit...Cd-ERRATA.html) so I have corrected that in the 4.0 version of the book.
Cheers,
Imar
|
|

July 6th, 2010, 06:25 PM
|
|
Friend of Wrox
|
|
Join Date: Jan 2004
Posts: 1,870
Thanks: 12
Thanked 20 Times in 20 Posts
|
|
Hi Imar - Thanking you for your time. I will be sure to go through the errata page and correct the book. Cheers...
__________________
Wind is your friend
Matt
|
|

July 6th, 2010, 06:48 PM
|
|
Friend of Wrox
|
|
Join Date: Jun 2008
Posts: 1,649
Thanks: 3
Thanked 141 Times in 140 Posts
|
|
I *suspect* that it doesn't allow IDs to be other than valid variable names, because it thinks you might want to use the ID *as* a name in a VB.NET or C# statement. *You* know you aren't going to do that, but VS is trying to protect you against yourself, no doubt.
|
|

July 6th, 2010, 06:58 PM
|
 |
Wrox Author
|
|
Join Date: Jun 2003
Posts: 17,089
Thanks: 80
Thanked 1,576 Times in 1,552 Posts
|
|
It can actually be pretty sure that's what you want. First of all, the markup is transferred to code and as such needs to result in valid identifiers. Secondly, there's a high probability that you need to program against those controls.
Why valid identifiers can't start with a number is an entirely different question. Then again; who cares. We (Holland) just made it to the finals of the World Cup. Time to party....
Imar
|
|

July 6th, 2010, 07:12 PM
|
|
Friend of Wrox
|
|
Join Date: Jan 2004
Posts: 1,870
Thanks: 12
Thanked 20 Times in 20 Posts
|
|
Hey congrats on the world cup, very nice effort. Although my profile says I live in Australia im a New Zealander. Sad that we didnt make it to the round of 16, mixed feelings that we are out without loosing a game, very proud of our effort. NZ only has a handful of professional players, the fact we even made the cup was monumental
Good luck with the finals Imar
__________________
Wind is your friend
Matt
|
|

July 6th, 2010, 07:51 PM
|
|
Friend of Wrox
|
|
Join Date: Jun 2008
Posts: 1,649
Thanks: 3
Thanked 141 Times in 140 Posts
|
|
Quote:
Originally Posted by Imar
It can actually be pretty sure that's what you want. First of all, the markup is transferred to code and as such needs to result in valid identifiers. Secondly, there's a high probability that you need to program against those controls.
|
Well, it's certainly possible that you need the ID for a field only for JavaScript usage, but of course VS can't really assume that.
Quote:
|
Why valid identifiers can't start with a number is an entirely different question.
|
And one that is left over from the days of Fortran II and before. <grin/>
Good luck writing a parser that can handle identifiers that start with numerals.
I've written a handful of languages in my (distant) past, and I'd have shot anybody who suggested I should allow such.
Quote:
|
Then again; who cares. We (Holland) just made it to the finals of the World Cup. Time to party....
|
And best of luck defeating the Germany/Spain winner!!! I think most of the world is pulling for you. Did you know it is the first time in many many years that a team has scored 3 goals in the semi-finals?
|
|

July 7th, 2010, 02:59 AM
|
 |
Wrox Author
|
|
Join Date: Jun 2003
Posts: 17,089
Thanks: 80
Thanked 1,576 Times in 1,552 Posts
|
|
Quote:
|
And best of luck defeating the Germany/Spain winner!!! I think most of the world is pulling for you. Did you know it is the first time in many many years that a team has scored 3 goals in the semi-finals?
|
Thank you; and no, I didn't know that..... ;-)
Imar
|
|

July 7th, 2010, 05:00 PM
|
|
Authorized User
|
|
Join Date: Dec 2009
Posts: 63
Thanks: 18
Thanked 0 Times in 0 Posts
|
|
Vaya Espana (Go Spain)!
Quote:
Originally Posted by Imar
We (Holland) just made it to the finals of the World Cup. Time to party....
Imar
|
Hey IMar,
You are sooo correct, it is time to party as my mother country has also made it to the finals. Good luck in the Sunday match up...as I'll be routing for Spain!
Both teams have accomplished so much and as usual the best team always wins...sometimes luck plays a big role, but I do not think so for this match-up. I like the way Holland plays, which by the way I cheered on in their semi-final, but my heart belongs to Spain.  We will have to wait for ALSO's decision as that octopus has been correct so far!
Fred Rosado
|
|
 |