Custom form control in asp.net

  • Thread starter Thread starter Yo mama
  • Start date Start date
Y

Yo mama

Hi!

I have problem using simple custom form control on asp.net page. It does not
do much. Just label and button. (It is for training purpose).
My control works fine when I use it in my windows application but I have
problem with asp.net.
I use <object id="Cont1" classid="http:Cont.dll#Contr.SomeCont">
When I run my page for the first time it loads and works. When I change
something in that control, build .dll and upload to root dir of my web app I
can't load it and I have an error that my control is undefined or coult not
be find.

Is there somebody who had similar problem and solved it? How did you do
that?

Hubert
 
If you made a winform custom control, you can't use it on an ASP.NET
page. You need to make a web custom control for that.


Steve C.
MCSD,MCAD,MCSE,MCP+I,CNE,CNA,CCNA
 
You can host a Winform control inside an ASP.NET page using the object tag.
Of course, you'll need .NET client side.

You could aklso have a llok at the SilverLight plugin.

Not sure what is the problem. My first thought would be to check the IIS log
to see if the request fails for some reason...
 
Problem is, that when I rebuild control after changing something in it that
control will not load to the page.
I think it is related to catching, but I don't know where to set up this.
Sometimes renaming dll helps.
I saw couple of examples. Authors can access control's public methods from
java scripts. I couldn't do that.
Did you do that in the past?
 
I gave this a try and don't remember to have seen this issue (we finally
choosed a click once application rather than hosting a control in a web
page). Are you using a proxy server maybe ?

As I said earlier my first move would be to check the IIS log to see what is
the response (as you said it says the DLL is not found, I would have a look
to see if the http query result is a 404 or some other error).

Good luck.
 
Back
Top