Wrox Programmer Forums

Need to download code?

View our list of code downloads.

| FAQ | Members List | Search | Today's Posts | Mark Forums Read
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 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 February 24th, 2008, 06:18 PM
Registered User
 
Join Date: Feb 2008
Location: , , .
Posts: 6
Thanks: 0
Thanked 0 Times in 0 Posts
Default C# Ch 10 Page 370 - Simple User Control

After creating my custom user control, when I try to drag it onto the design view of default.aspx, all that happens is I create a link, instead of inserting ym control into the form as shown in the book.

I have got around this by completing the exercise by using the 2 appropriate source lines to insert the control into ASP forms, but I was wondering why the dragging method did not work. Is this a setting in visual studio?

I am using Visual Web Developer Express 2008.

  #2 (permalink)  
Old February 24th, 2008, 06:27 PM
Imar's Avatar
Wrox Author
Points: 72,073, Level: 100
Points: 72,073, Level: 100 Points: 72,073, Level: 100 Points: 72,073, Level: 100
Activity: 0%
Activity: 0% Activity: 0% Activity: 0%
 
Join Date: Jun 2003
Location: Utrecht, Netherlands.
Posts: 17,089
Thanks: 80
Thanked 1,587 Times in 1,563 Posts
Default

Is the application error free? (Try building it). I think I have seen this once before when the application had errors, or when the UC wasn't valid....

Imar
---------------------------------------
Imar Spaanjaars
http://Imar.Spaanjaars.Com
Everyone is unique, except for me.
Author of Beginning ASP.NET 3.5 : in C# and VB, ASP.NET 2.0 Instant Results and Dreamweaver MX 2004
Want to be my colleague? Then check out this post.
  #3 (permalink)  
Old February 25th, 2008, 04:16 AM
Registered User
 
Join Date: Feb 2008
Location: , , .
Posts: 6
Thanks: 0
Thanked 0 Times in 0 Posts
Default

The application is definately error free.
If I add the lines to register my control, and then call my control in source view it works fine. So really it is not a big problem, I just wondered why the dragging method did not work?

  #4 (permalink)  
Old February 25th, 2008, 01:52 PM
Registered User
 
Join Date: Feb 2008
Location: , , .
Posts: 6
Thanks: 0
Thanked 0 Times in 0 Posts
Default

I have found the answer, and also the answer to my other problem!
It is a little bit stupid!

I was using a directory with part of the name being "c#".
Because the # was not a legal character for this it caused my problems. It also stopped the ASP.NET configuration tool from working.

As soon as I changed the directory name all the problems stopped occurring. It is something worth bearing in mind for the future.

  #5 (permalink)  
Old February 25th, 2008, 01:53 PM
Imar's Avatar
Wrox Author
Points: 72,073, Level: 100
Points: 72,073, Level: 100 Points: 72,073, Level: 100 Points: 72,073, Level: 100
Activity: 0%
Activity: 0% Activity: 0% Activity: 0%
 
Join Date: Jun 2003
Location: Utrecht, Netherlands.
Posts: 17,089
Thanks: 80
Thanked 1,587 Times in 1,563 Posts
Default

Hi there,

Maybe there is something wrong with your setup or with your site / setup? Here's what I just did and which worked fine:

1. Choose File | New Web Site. Create a new C# web site

2. Added a new User Control to the site

3. Dragged the UC onto the Design View of Default.aspx. Worked as expected and I was able to open the Smart Tasks panel of the UC.

AFAIK, this is all how it's supposed to work. It works for me every time.

Maybe your situation is different? (I don't have the book, so I don't know the exact steps you are following). In that case, can you elaborate?

Imar

---------------------------------------
Imar Spaanjaars
http://Imar.Spaanjaars.Com
Everyone is unique, except for me.
Author of ASP.NET 2.0 Instant Results and Beginning Dreamweaver MX / MX 2004
 


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
C# Ch 10 Page 362 surefire BOOK: Beginning ASP.NET 2.0 BOOK VB ISBN: 978-0-7645-8850-1; C# ISBN: 978-0-470-04258-8 5 February 25th, 2008 01:55 PM
Page 370 - New ContextMenu MajorD BOOK: Beginning Visual Basic 2005 ISBN: 978-0-7645-7401-6 2 July 25th, 2007 10:26 AM
Error with CH. 10 ObjectDataSource Control in C# dramsey BOOK: Beginning ASP.NET 2.0 BOOK VB ISBN: 978-0-7645-8850-1; C# ISBN: 978-0-470-04258-8 7 February 14th, 2007 11:09 PM
Chapter 10 User Control Problem sookarama BOOK: Beginning ASP.NET 2.0 BOOK VB ISBN: 978-0-7645-8850-1; C# ISBN: 978-0-470-04258-8 5 October 16th, 2006 06:24 AM
Code snippet error on page 370 cebartling BOOK: Professional Java Development with the Spring Framework 0 September 18th, 2005 10:00 PM



All times are GMT -4. The time now is 09:39 PM.


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