Last post Dec 07, 2005 03:07 PM by sbyard
Dec 07, 2005 01:52 PM|interwanderer1|LINK
I have been trying to make a simple server control. but it doesn't work. Can someone take a look and give me a hint? the code is probably OK but the way I use those files is probably wrong. I just put them both in 1 folder and then go to the "simple.aspx"
file with my browser.
I have an "simple.aspx" page and a "simple.vb" file.
the simple.vb file should be the server control.
the simple. aspx file:
I get an error on this line:
I think I have to make a .dll of the .vb file and put it in the bin folder of my web application. I have visual studio 2005 standard edition. how do I make a .DLL of the simple.aspx file?
thx in advance,
Dec 07, 2005 03:07 PM|sbyard|LINK
The Assembly attribute should be the name of Project (usually the DLL name too). This is where your error is.
Tag prefix looks OK could be anything you like - if a bit long
Your namespace looks OK.
Here is an example I posted somewhere else earlier today. Its C# VS2005, but you should be able to follow it and use the information.
This is my custom control class. I simply extend an existing one - so not much work. Its in a separate project called "CustomCalendar". This is also the name of the DLL referenced by the web project that uses it (below)
if (value ==
Enabled = false;
VisibleDate = (Convert.ToDateTime(value));
Here is the web page with the REGISTER tag. The web site is in a separate project and references the custom project above to form a solution (it cold jus reference the DLL's though)
Page Language="C#" %>
void Page_Load(object sender,
CustCal1.VisibleDateCustom = DateTime.Now;
void Button1_Click(object sender,
CustCal1.VisibleDateCustom = null;