Help on user controls?

S

serge calderara

Dear all
I have build a simple Web user control, that I have draged on a web form.
When executed my applciation I get an error mesage saying :

"A page can have only one server-side Form tag"

What does that means?
The HTML code has been generated automatically by dragging the control, I
could not find any error.

Here is the produce code :

===============================
<%@ Register TagPrefix="uc1" TagName="LastHistory" Src="LastHistory.ascx" %>
<%@ Page Language="vb" AutoEventWireup="false"
Codebehind="WebLeftMargin.aspx.vb" Inherits="ServiceClient.WebLeftMargin"%>
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
<HTML>
<HEAD>
<title>WebLeftMargin</title>
<meta content="Microsoft Visual Studio .NET 7.1" name="GENERATOR">
<meta content="Visual Basic .NET 7.1" name="CODE_LANGUAGE">
<meta content="JavaScript" name="vs_defaultClientScript">
<meta content="http://schemas.microsoft.com/intellisense/ie5"
name="vs_targetSchema">
</HEAD>
<body bgColor="#ffcc66">
<form id="Form1" method="post" runat="server">
</form>
<uc1:lasthistory id="LastHistory1" runat="server"></uc1:lasthistory>
</body>
</HTML>
============================================

Any help will be appreciate
Regards
Serge
 
S

Steve C. Orr [MVP, MCSD]

It looks like your page contains one form.
I bet your user control also contains a form.
That would total 2 server side forms in the same page, which is not allowed
in ASP.NET 1.x.
 

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

Forum statistics

Threads
473,769
Messages
2,569,579
Members
45,053
Latest member
BrodieSola

Latest Threads

Top