Wrox Programmer Forums

Need to download code?

View our list of code downloads.

| FAQ | Members List | Calendar | Search | Today's Posts | Mark Forums Read
BOOK: Professional Web Parts and Custom Controls ASP.NET ISBN: 0-7645-7860-X
This is the forum to discuss the Wrox book Professional Web Parts and Custom Controls with ASP.NET 2.0 by Peter Vogel; ISBN: 9780764578601
Welcome to the p2p.wrox.com Forums.

You are currently viewing the BOOK: Professional Web Parts and Custom Controls ASP.NET ISBN: 0-7645-7860-X section of the Wrox Programmer to Programmer discussions. This is a community of tens of thousands of software programmers and website developers including Wrox book authors and readers. As a guest, you can read any forum posting. By joining today you can post your own programming questions, respond to other developers’ questions, and eliminate the ads that are displayed to guests. Registration is fast, simple and absolutely free .
DRM-free e-books 300x50
 
 
Thread Tools Search this Thread Display Modes
  #1 (permalink)  
Old March 16th, 2006, 07:02 AM
Registered User
 
Join Date: Mar 2006
Location: Ennis, Clare, Ireland.
Posts: 6
Thanks: 0
Thanked 0 Times in 0 Posts
Default Updates?

I downloaded the code for the book, and tried running chapters 10-12. I can't get any of these to run. I've tried both the VB and C# versions. The C# versions are totally incomplete and what is there is extremely low quality.

My question: Are you going to finish this thing and give us example code that actually works?
  #2 (permalink)  
Old April 7th, 2006, 11:18 PM
Registered User
 
Join Date: Apr 2006
Location: , , .
Posts: 1
Thanks: 0
Thanked 0 Times in 0 Posts
Default

Amen to that !!! chapters 10 - 12 are what I really need. I'll think twice before buying another wrox book.

  #3 (permalink)  
Old April 10th, 2006, 02:17 PM
jminatel's Avatar
Wrox Staff
Points: 18,940, Level: 59
Points: 18,940, Level: 59 Points: 18,940, Level: 59 Points: 18,940, Level: 59
Activity: 100%
Activity: 100% Activity: 100% Activity: 100%
 
Join Date: May 2003
Location: Indianapolis, IN, USA.
Posts: 1,945
Thanks: 73
Thanked 139 Times in 101 Posts
Default

GeekyMonkey or andeezlemoyo: do either of you have a specific example or two of broken code or the types of errors you are seeing that we can use as a starting point to help get this fixed? We want to help but we don't have much to go on from these posts.

Jim Minatel
Senior Acquisitions Editor
Wiley Technology Publishing
WROX Press
Blog: http://wroxblog.typepad.com/
Jim's Book of the week: No book this week - Donate to the Red Cross!
  #4 (permalink)  
Old April 11th, 2006, 08:26 AM
kjt kjt is offline
Registered User
 
Join Date: Apr 2006
Location: Cambridge, , United Kingdom.
Posts: 2
Thanks: 0
Thanked 0 Times in 0 Posts
Default

Trying to compile the code for Chapter 12, the "Custom Control Case Study", you get the following error:
"File 'WebUserControl.ascx' was not found"
The aspx pages have only a couple of lines - not what you would expect from the case study provided in the book.
The aspx code pages as part of a proper working project are really crucial for this book as it seems to leave them out - quite disappointing.
Please can you try and get the real code that was used to write the book?
Thanks,
Kieran Toon

  #5 (permalink)  
Old April 11th, 2006, 10:13 AM
kjt kjt is offline
Registered User
 
Join Date: Apr 2006
Location: Cambridge, , United Kingdom.
Posts: 2
Thanks: 0
Thanked 0 Times in 0 Posts
Default

If you get the following error when running one of the examples, just delete the ASPNETDB.MDF file under the App_Data folder

Procedure or Function 'aspnet_PersonalizationPerUser_GetPageSettings' expects parameter '@TimeZoneAdjustment', which was not supplied

I needed to do this to get one of the examples in Chapter 5 working.
Compiling and running the application out of debug mode might also help.

  #6 (permalink)  
Old April 17th, 2006, 05:02 AM
Registered User
 
Join Date: Mar 2006
Location: Ennis, Clare, Ireland.
Posts: 6
Thanks: 0
Thanked 0 Times in 0 Posts
Default

Unfortunately this book seems to be written by a VB only programmer who doesn't have a clue about C#. The code examples in the book that are supposed to be in C# are a mix of C# and VB which comes no where close to compiling. He just gave up instead of releasing working sample C# code. I think Wrox must have pushed him to get C# into the description to get more people to buy this piece of rubbish.

  #7 (permalink)  
Old April 17th, 2006, 08:35 AM
Registered User
 
Join Date: Mar 2006
Location: Ennis, Clare, Ireland.
Posts: 6
Thanks: 0
Thanked 0 Times in 0 Posts
Default

Jminatel - I could write an entire book about the errors in this book and error and omissions in the source code. Sorry if I've been rude, but every time I pick this thing up I get angry. I was most interrested in chapeter 9. A quick glance thru and I saw this on p277
 
Code:
string strTestControl = Me.ControlToValidate;

This line is half vb and half c#. There are many more examples of syntax problems in the c# code.

I've deleted the source code from my computer (because it was rubbish) but to answer your quesion I just downloaded again http://media.wiley.com/product_ancil..._Web_Parts.zip.

First off - the directory structure when you unzip everything is wrong. Opening the projects gives errors because the related projects aren't in the right place.

Now let's try the website in chapter 11. Here he doesn't even try to include c# code. I'M flexible. I'll proceed in VB. But I get a database connection error. I add these lines to web.config to fix it: (my own knowledge - beginners would be stuck at this point)
Code:
<connectionStrings>
        <clear/>
        <add name="LocalSqlServer" connectionString="data source=.\SQLEXPRESS;Integrated Security=SSPI;AttachDBFilename=|DataDirectory|aspnetdb.mdf;User Instance=false" />
    </connectionStrings>
     There's no reason this shouldn't have been there in the download.

Now I get error:
Quote:
quote:Procedure or Function 'aspnet_PersonalizationPerUser_GetPageSettings' expects parameter '@TimeZoneAdjustment', which was not supplied.
so I take this out of the stored procedure parameters:
Code:
@TimeZoneAdjustment INT
and add this instead
Code:
    DECLARE @TimeZoneAdjustment INT
    SET @TimeZoneAdjustment = 0
Now I get error:
Quote:
quote:@CurrentTimeUtc is not a parameter for procedure
so I add this parameter
Code:
@CurrentTimeUtc DATETIME
. Again - beginners would not be able to solve this problem.

Now it runs and I get a Customize button. Clicking this does nothing. What the F!!! I went thru all that hassle to get this running and now look at the souce files - there are only 2 VB files with 3 empty functions total!

Try chapter 12 by opening Chapter12.sln. It Builds! Fantastic! Let's see what it does. Open the VB project and there's a source file with a CustomerInformation WebPart control. Now I want to see the C# version. It contains a single source file Address.cs which has 2 empty functions!




  #8 (permalink)  
Old April 17th, 2006, 08:41 AM
jminatel's Avatar
Wrox Staff
Points: 18,940, Level: 59
Points: 18,940, Level: 59 Points: 18,940, Level: 59 Points: 18,940, Level: 59
Activity: 100%
Activity: 100% Activity: 100% Activity: 100%
 
Join Date: May 2003
Location: Indianapolis, IN, USA.
Posts: 1,945
Thanks: 73
Thanked 139 Times in 101 Posts
Default

GeekyMonkey: No need to apologize to me, I've got thicker skin than that and I suspect Peter the author does too. I'm sorry we haven't been able to address this yet. Peter's usually very responsive, I've been trying to get him but he does do a lot of travel for training and consulting. I'll keep after him until we can get this resolved.

Jim Minatel
Senior Acquisitions Editor
Wiley Technology Publishing
WROX Press
Blog: http://wroxblog.typepad.com/
Jim's Book of the week: No book this week - Donate to the Red Cross!
  #9 (permalink)  
Old April 17th, 2006, 09:34 AM
Registered User
 
Join Date: Mar 2006
Location: Ennis, Clare, Ireland.
Posts: 6
Thanks: 0
Thanked 0 Times in 0 Posts
Default

Let's try Chapter 10. I know how to fix the connection string problem now. Now I get the error:
Quote:
quote:A ConsumerConnectionPoint has already been added with ID 'default'. Parameter name: connectionPoints
. I figured it out - it's because this function must be in both of the C# and VB Dlls that are included in the project. I'll remove the C# one (since it probably doesn't work anyway).

Now I get an error because the ASPX file registers both of these DLLs. I'll have to remove this line as well, and also change the cc2 to cc1 in the FirstSample VB page.

I also have to exclue FirstSampleCS.aspx trying to get it to compile. Still no good. I now look to Chapter10Project\Chapter10\Chapter10CustomControls VB\bin\Debug. Here I find binary files for chapter 11!

I give up.
  #10 (permalink)  
Old April 18th, 2006, 05:20 AM
Authorized User
 
Join Date: Dec 2005
Location: Goderich, Ontario, Canada.
Posts: 11
Thanks: 0
Thanked 0 Times in 0 Posts
Default

Looking at the problems, it appears that most of the issues are around the C# code--so I'll do that first.

When you have eliminated all which is impossible, then whatever remains, however improbable, must be the truth.

- Sherlock Holmes, as recorded by Sir A. C. Doyle in "The Blanched Soldier"
 


Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off
Trackbacks are Off
Pingbacks are On
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
Email Register for Updates HelpWanted ASP.NET 1.0 and 1.1 Basics 3 October 31st, 2006 04:29 PM
Parameter Updates HelmutArnold Reporting Services 3 October 23rd, 2006 09:06 AM
What happens if someone else updates the data jaideepc ADO.NET 2 August 11th, 2004 12:02 PM
Transactional UPDATEs djm2cmu BOOK: ASP.NET Website Programming Problem-Design-Solution 0 January 20th, 2004 11:42 AM



All times are GMT -4. The time now is 07:47 AM.


Powered by vBulletin®
Copyright ©2000 - 2019, Jelsoft Enterprises Ltd.
© 2013 John Wiley & Sons, Inc.