Problem creating DLL for a composite control

R

ree32

I have a ASP web page that has its own codebehind vb file.

But then I am using a composite control in that page. The code for the
control is built from a vb file. But I having problems as I can't get
MS VS.net to create the DLL of the composite control in the BIN
directory.

I thing it might be to do with page directive code.

Can someone tell me if they see a mistake below?

webpage.aspx:
------------
<%@ Page Language="vb" AutoEventWireup="false"
Codebehind="webpage.aspx.vb" Inherits="projectName.webpage" %>
<%@ Register TagPrefix="Cctrl" Namespace="CompControls"
Assembly="compositeControl" %>

....
<form>...
<Cctrl:compositeControlrunat="server" />

_______________________________________

webpage.aspx.vb:
-----------
Imports System.Text.RegularExpressions
Public Class webpage
Inherits System.Web.UI.Page

.......

_________________________________

compositeControl.vb :
-------------
Imports System
Imports System.Web
Imports System.Web.UI
Imports System.Web.UI.WebControls

Namespace CompControls

Public Class compositeControl: Inherits Control
Protected Overrides Sub CreateChildControls()



__________________________________

So can someone see any mistakes.

Or do I have to create a separate project for the composite controls
to make the DLLs. Then copy them over to the bin folder of this
webpage project?
 
J

John Saunders

ree32 said:
I have a ASP web page that has its own codebehind vb file.

But then I am using a composite control in that page. The code for the
control is built from a vb file. But I having problems as I can't get
MS VS.net to create the DLL of the composite control in the BIN
directory.

I thing it might be to do with page directive code.

Can someone tell me if they see a mistake below?

webpage.aspx:
------------
<%@ Page Language="vb" AutoEventWireup="false"
Codebehind="webpage.aspx.vb" Inherits="projectName.webpage" %>
<%@ Register TagPrefix="Cctrl" Namespace="CompControls"
Assembly="compositeControl" %>

...
<form>...
<Cctrl:compositeControlrunat="server" />

_______________________________________

webpage.aspx.vb:
-----------
Imports System.Text.RegularExpressions
Public Class webpage
Inherits System.Web.UI.Page

......

_________________________________

compositeControl.vb :
-------------
Imports System
Imports System.Web
Imports System.Web.UI
Imports System.Web.UI.WebControls

Namespace CompControls

Public Class compositeControl: Inherits Control
Protected Overrides Sub CreateChildControls()



__________________________________

So can someone see any mistakes.

Or do I have to create a separate project for the composite controls
to make the DLLs. Then copy them over to the bin folder of this
webpage project?

You have to create a separate project for your controls. You can then
reference that project from your web project, and VB.NET will put the dll
into the bin directory.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

No members online now.

Forum statistics

Threads
473,989
Messages
2,570,207
Members
46,783
Latest member
RickeyDort

Latest Threads

Top