Velocity Reviews - Computer Hardware Reviews

Velocity Reviews > Newsgroups > Programming > ASP .Net > RE: Custom Controls driving me nuts

Reply
Thread Tools

RE: Custom Controls driving me nuts

 
 
=?Utf-8?B?Q293Ym95IChHcmVnb3J5IEEuIEJlYW1lcikgLSBNVlA=?=
Guest
Posts: n/a
 
      06-03-2005
I hope this is not overly blunt, but you are asking a specific question in a
very general way and hoping someone else has had similar issues and can
validate your thinking. The problem is this: even if someone has had a
similar problem and can commisurate, it does not mean the two of you have
found a bug. It may mean the two of you are making the same error due to the
same, or similar, misunderstanding of .NET. I have three choices:

1. Ask for something to repro
2. Continue making controls until I hit your issue, if ever
3. Attempt to make a control that does not always render 100% of the HTML
and throw it out for you to examine to see if it is the same issue you are
having

I have created tons of controls, from user controls to compiled server
controls, some that inherit from other controls and some that are truly
custom. To date, I have not seen the issue you are describing. Without a
method of reproing your issue (i.e. a bit of sample code that repros the
issue), I have no method of determining if it is a bug or a misconception.

My suggestions:

1. Set up the simplest control and page that illustrates the issue you are
having and post it here. Then, someone can take the code and look at it and
determine whether or not there is a bug. If so, there will likely be either
a) a patch or b) a workaround. If not, you will likely get a much better
answer on how to fix your issue.

2. Step through the code completely and watch what goes on. You will likely
have to include the control project and use a project reference (rather than
a compiled code reference) to determine what is happening. This may not solve
the issue, but watching the ordering of methods firing and the call stack is
a wonderful way to understand the inner workings of .NET (at least I find it
fascinating, but I am often confused with a mega geek :->).

--
Gregory A. Beamer
MVP; MCP: +I, SE, SD, DBA

***************************
Think Outside the Box!
***************************


"david" wrote:

> Hello hello.
>
> I'm trying to create a couple of custom controls.
> Some of them needs to have other controls nested inside.
> Simple stuff really (if you do not count getting it to work with the
> VS.Net designer).
>
> I'm having a problem though. Not sure if it's a bug, but it could be.
> Seems like ASP.Net takes the HTML content nested in the custom control,
> throws it up in the air, catches some of it, and whatever it catches, it
> outputs to the browser. (It's not really that random, but you get the
> idea).
>
> To demonstrate, I've made a test case.
> - Compile the attached custom control ("_") and drop it in a bin/
> folder in your IIS web.
> - Also drop test.aspx{,.cs} in your IIS web.
>
> Browse to the test page.
> You'll notice that the parts of the page marked in green and red does
> not look alike.
>
> Open test.aspx, and you'll notice that they really /should/, since it's
> the same HTML.
>
> Do a 'view source' in your browser, and you'll notice all the missing
> bits and pieces.
>
> When you're all done with that, you can try again, but this time remove
> line 39 of test.aspx first. Magic.
>
>
> My question is, am I doing something wrong, or is this a bug?
>
>

 
Reply With Quote
 
 
 
 
david
Guest
Posts: n/a
 
      06-03-2005
Cowboy (Gregory A. Beamer) - MVP wrote:
> I hope this is not overly blunt, but you are asking a specific question in a
> very general way and hoping someone else has had similar issues and can
> validate your thinking. The problem is this: even if someone has had a
> similar problem and can commisurate, it does not mean the two of you have
> found a bug. It may mean the two of you are making the same error due to the
> same, or similar, misunderstanding of .NET. I have three choices:
>
> 1. Ask for something to repro
> 2. Continue making controls until I hit your issue, if ever
> 3. Attempt to make a control that does not always render 100% of the HTML
> and throw it out for you to examine to see if it is the same issue you are
> having
>
> I have created tons of controls, from user controls to compiled server
> controls, some that inherit from other controls and some that are truly
> custom. To date, I have not seen the issue you are describing. Without a
> method of reproing your issue (i.e. a bit of sample code that repros the
> issue), I have no method of determining if it is a bug or a misconception.
>
> My suggestions:
>
> 1. Set up the simplest control and page that illustrates the issue you are
> having and post it here. Then, someone can take the code and look at it and
> determine whether or not there is a bug. If so, there will likely be either
> a) a patch or b) a workaround. If not, you will likely get a much better
> answer on how to fix your issue.


Hello Gregory;

I'm not sure what happened.

Either the usenet server at Microsoft removed the attachments, or you
need a new pair of glasses .

A test case was attached to my posting that clearly illustrates the problem.

It's as minimal as it gets, it's about 50 lines of code.

I have uploaded it to a FTP server, in case that will get through to you
better. Please see below.

ftp://130.227.153.74/testcases/customcontrol.zip
ftp://130.227.153.74/testcases/customcontrol-demo.png
 
Reply With Quote
 
 
 
Reply

Thread Tools

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 On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
Cisco 350 bridge firmware, driving me nuts!? mcdent@gmail.com Cisco 2 04-10-2006 04:02 PM
Frame relay MTUs driving me nuts - what's going on??? groupstudy2001@yahoo.co.uk Cisco 5 01-15-2006 03:12 AM
PIX501 driving us nuts...! jjr@asiamail.com Cisco 14 08-27-2005 12:59 AM
Please help ! (IOS is driving me nuts !) JustMe Cisco 7 05-20-2004 05:51 PM
PPPoE dialup/tunnel/nhrp driving me nuts ... gkg@gmx.de Cisco 0 11-30-2003 07:28 AM



Advertisments