Wrox Programmer Forums
|
BOOK: ASP.NET 2.0 Instant Results ISBN: 978-0-471-74951-6
This is the forum to discuss the Wrox book ASP.NET 2.0 Instant Results by Imar Spaanjaars, Paul Wilton, Shawn Livermore; ISBN: 9780471749516
Welcome to the p2p.wrox.com Forums.

You are currently viewing the BOOK: ASP.NET 2.0 Instant Results ISBN: 978-0-471-74951-6 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
 
Old November 4th, 2006, 08:51 PM
Friend of Wrox
 
Join Date: Jul 2006
Posts: 238
Thanks: 0
Thanked 2 Times in 2 Posts
Send a message via MSN to rsearing
Default Chapter 1--what is the use of this funct?

Please forgive if this is blatantly obvious--just wondering what the "GetDiaryEntriesByDateAsCollection" and "GetDiaryEventsByDateCollection" functions serve?

I Deleted the DiaryEventCollection Class and the DiaryEntryCollection class and removed the above functions and the project seemed to work ok. I was able to save and edit entries and events..they all displayed ok...just curious what these are for?

Kind Regards,
Rob

 
Old November 6th, 2006, 03:55 PM
Imar's Avatar
Wrox Author
 
Join Date: Jun 2003
Posts: 17,089
Thanks: 80
Thanked 1,576 Times in 1,552 Posts
Default

Hi Rob,

Since I didn't write that chapter I am not 100% sure, but I think these methods are indeed obsolete.

Their implementation returns a simple list with new DiaryEvent objects, but only their ID is set.

However, you could extend these methods to make them a bit more useful. Instead of setting just a simple ID, you can fill the entire DiaryEvent object. Similar code is used in chapters like the BugBase, although there not a custom collection is used, but something like List (Of Bug). But, the principle is the same: you can return strongly typed objects back to the calling code.

Hope this helps,

Imar
---------------------------------------
Imar Spaanjaars
Everyone is unique, except for me.
Author of ASP.NET 2.0 Instant Results and Beginning Dreamweaver MX / MX 2004
Want to be my colleague? Then check out this post.
 
Old November 6th, 2006, 05:42 PM
Friend of Wrox
 
Join Date: Jul 2006
Posts: 238
Thanks: 0
Thanked 2 Times in 2 Posts
Send a message via MSN to rsearing
Default

Phew--thought I was going crazy.

Thanks for the reply!

Kind Regards,
Rob

 
Old November 6th, 2006, 05:43 PM
Imar's Avatar
Wrox Author
 
Join Date: Jun 2003
Posts: 17,089
Thanks: 80
Thanked 1,576 Times in 1,552 Posts
Default

You're welcome.


Ctrl+Shift+F (find in files / entire solution) always brings a lot of interesting information.... ;)

Imar
---------------------------------------
Imar Spaanjaars
Everyone is unique, except for me.
Author of ASP.NET 2.0 Instant Results and Beginning Dreamweaver MX / MX 2004
Want to be my colleague? Then check out this post.





Similar Threads
Thread Thread Starter Forum Replies Last Post
Chapter 2 - End of chapter exercises whizzkid1892 BOOK: Beginning PHP5, Apache, and MySQL Web Development ISBN: 978-0-7645-7966-0 1 July 30th, 2008 12:02 PM
Generics chapter 12 difficult chapter i found ...? Larryz C# 2005 1 July 4th, 2007 09:40 PM
database connection(query) within javascript funct [email protected] Pro JSP 0 April 5th, 2006 06:48 AM
Roll Up\Cube\Compute aggregate funct. in Access? donnie200 Access VBA 7 January 25th, 2005 06:23 PM





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