I want to use my custom control (.cs) in my web application. Custom control
is in the same assembly as my application. I want to know the name of the
assembly (.dll) file so i can add it's <@dotnet.itags.org.Pegister Assembly="abc.dll"> name.
But in asp.net 2.0 i can't find the assembly. It is not compiled under the
/bin folder. Where it is, or how can i give a reference to it?re:
> I want to use my custom control (.cs) in my web application.
Custom controls aren't located in *.cs files.
Classes are included in *.cs files.
Can you clarify what you are looking for ?
Juan T. Llibre, ASP.NET MVP
ASP.NET FAQ : http://asp.net.do/faq/
ASPNETFAQ.COM : http://www.aspnetfaq.com/
Foros de ASP.NET en Espaol : http://asp.net.do/foros/
======================================
"Umut Tezduyar" <umut@dotnet.itags.org.tezduyar.com> wrote in message
news:uxcKX7t6FHA.2036@dotnet.itags.org.TK2MSFTNGP14.phx.gbl...
> I want to use my custom control (.cs) in my web application. Custom contro
l is in the
> same assembly as my application. I want to know the name of the assembly (
.dll) file so
> i can add it's <@dotnet.itags.org.Pegister Assembly="abc.dll"> name. But in asp.net 2.0 i c
an't find the
> assembly. It is not compiled under the /bin folder. Where it is, or how ca
n i give a
> reference to it?
I mean, not the *.ascx (User controls), custom control.
Let me ask my question in this way: I can't add my custom control in a web
page because i don't know what to write in the <@dotnet.itags.org.Page Assembly=''> register
tag.
"Juan T. Llibre" <nomailreplies@dotnet.itags.org.nowhere.com> wrote in message
news:Oo7QLKu6FHA.2036@dotnet.itags.org.TK2MSFTNGP14.phx.gbl...
> re:
> Custom controls aren't located in *.cs files.
> Classes are included in *.cs files.
> Can you clarify what you are looking for ?
>
> Juan T. Llibre, ASP.NET MVP
> ASP.NET FAQ : http://asp.net.do/faq/
> ASPNETFAQ.COM : http://www.aspnetfaq.com/
> Foros de ASP.NET en Espaol : http://asp.net.do/foros/
> ======================================
> "Umut Tezduyar" <umut@dotnet.itags.org.tezduyar.com> wrote in message
> news:uxcKX7t6FHA.2036@dotnet.itags.org.TK2MSFTNGP14.phx.gbl...
>
OK...
For that, check out :
http://support.microsoft.com/defaul...kb;en-us;321749
The proper tag is :
<%@dotnet.itags.org. Register TagPrefix="Custom" Namespace="CustomControlNamespace" Assembly=
"CustomControl" %>
Custom is an alias that you associate with a namespace.
CustomControlNamespace is a namespace in which classes of an assembly are en
closed.
CustomControl is the name of the assembly file without an extension (.dll).
Juan T. Llibre, ASP.NET MVP
ASP.NET FAQ : http://asp.net.do/faq/
ASPNETFAQ.COM : http://www.aspnetfaq.com/
Foros de ASP.NET en Espaol : http://asp.net.do/foros/
======================================
"Umut Tezduyar" <umut@dotnet.itags.org.tezduyar.com> wrote in message news:uI%23L45u6FHA.1000@dotnet.itags.org.tk2msftngp13.p
hx.gbl...
>I mean, not the *.ascx (User controls), custom control.
>
> Let me ask my question in this way: I can't add my custom control in a web
> page because i don't know what to write in the <@dotnet.itags.org.Page Assembly=''> registe
r
> tag.
>
>
> "Juan T. Llibre" <nomailreplies@dotnet.itags.org.nowhere.com> wrote in message
> news:Oo7QLKu6FHA.2036@dotnet.itags.org.TK2MSFTNGP14.phx.gbl...
On Wed, 16 Nov 2005 10:52:05 -0800, "Umut Tezduyar"
<umut@dotnet.itags.org.tezduyar.com> wrote:
>I want to use my custom control (.cs) in my web application. Custom control
>is in the same assembly as my application.
>
Is this 2.0? (I assume so based on your previous questions). Your
custom control must be in App_Code, correct?
Something like this:
namespace OTC
{
public class MyCustomControl : WebControl
{
protected override void Render(HtmlTextWriter writer)
{
writer.Write("This is my custom control");
base.Render(writer);
}
}
}
>I want to know the name of the
>assembly (.dll) file so i can add it's <@dotnet.itags.org.Pegister Assembly="abc.dll"> name.
>But in asp.net 2.0 i can't find the assembly. It is not compiled under the
>/bin folder. Where it is, or how can i give a reference to it?
>
ASP.NET builds App_Code as a separate assembly, and the runtime will
recognize "App_Code" as an assembly name in a reference directive.
<%@dotnet.itags.org. Register Assembly="App_Code" TagPrefix="otc" Namespace="OTC" %>
...
<otc:MyCustomControl runat="Server" id="boo" />
Scott
http://www.OdeToCode.com/blogs/scott/
0 comments:
Post a Comment