Wrox Programmer Forums
|
BOOK: Beginning ASP.NET 2.0 BOOK VB ISBN: 978-0-7645-8850-1; C# ISBN: 978-0-470-04258-8
This is the forum to discuss the Wrox book Beginning ASP.NET 2.0 by Chris Hart, John Kauffman, David Sussman, Chris Ullman; ISBN: 9780764588501
Welcome to the p2p.wrox.com Forums.

You are currently viewing the BOOK: Beginning ASP.NET 2.0 BOOK VB ISBN: 978-0-7645-8850-1; C# ISBN: 978-0-470-04258-8 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 February 20th, 2006, 07:09 PM
Authorized User
 
Join Date: Jun 2003
Posts: 15
Thanks: 0
Thanked 0 Times in 0 Posts
Default chapter 13 building an index page

Hi all,

I've tried to do this part of the chapter for my own website using access. But when I run the application instead of showing the image on the imagebutton it just says "Submit Query".

I have created a folder via the solution explorer and added existing image files through it.

When the image location string is read from the database, I append the folder name exactly as in the example.

I have also tried specifying the folder name in the database and just retrieving the string. But this doesn't work either.

Finally I moved the images to the root of the solution and it actually worked.

So it looks like there is a problem getting access to the folder that contains the images. My question is why is this happening and what can i do about it? I don't really want to have all my images floating around the root of the site.

If anyone can give me any help on this I would be grateful.

Many thanks
DRB2k2
 
Old February 21st, 2006, 07:12 AM
Authorized User
 
Join Date: Jun 2003
Posts: 15
Thanks: 0
Thanked 0 Times in 0 Posts
Default

ok I've found out what the problem was you need to put a ~ in to tell it to look at the local structure.

Eval("PictureURL","~/images/thumb_{0}")

I'm not sure if this is a typo in the book or not, but i'm guessing it will be
 
Old February 21st, 2006, 01:36 PM
Wrox Author
 
Join Date: Jun 2004
Posts: 59
Thanks: 0
Thanked 0 Times in 0 Posts
Default

Hi,
   In the actual book example you do not need the ~, although you might well do for your own site.

If you point it at the ProductImages directory as follows:

Eval("PictureURL","ProductImages/thumb_{0}")

then it works fine for me using the Begin/Chapter13 code. It depends on the structure and setup of your own particular site.

Chris

Chris Ullman
Programmer/Technical Author
http://www.cuasp.co.uk
 
Old March 4th, 2006, 12:30 PM
Authorized User
 
Join Date: May 2004
Posts: 10
Thanks: 0
Thanked 0 Times in 0 Posts
Default

This seems to be a problem for me if I use FIREFOX. However on using IE it works fine.

So I am using ie for this now.


 
Old March 5th, 2006, 06:23 PM
Authorized User
 
Join Date: Jun 2003
Posts: 15
Thanks: 0
Thanked 0 Times in 0 Posts
Default

aha Tequin I see, I use firefox too. I didn't even try to view the page in IE.
However adding the little ~ does work should you decide to go back to Firefox.
Cheers
DRB2k2
 
Old March 5th, 2006, 07:22 PM
Authorized User
 
Join Date: May 2004
Posts: 10
Thanks: 0
Thanked 0 Times in 0 Posts
Default

drb2k2 thanks.. I will try that.. I have another problem though.. which I have made a post for let me know if you get the same problem at that point in the chapter.








Similar Threads
Thread Thread Starter Forum Replies Last Post
Chapter 13 problem(undefined index) linux-penguin BOOK: Beginning PHP5, Apache, and MySQL Web Development ISBN: 978-0-7645-7966-0 2 February 15th, 2008 06:10 AM
Page 468-474 Chapter 13 michaelcode BOOK: Beginning ASP.NET 2.0 BOOK VB ISBN: 978-0-7645-8850-1; C# ISBN: 978-0-470-04258-8 0 July 24th, 2006 09:00 AM
Chapter 13 page 444 DRAYKKO Beginning VB 6 1 April 19th, 2006 07:10 PM





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