Hi

I am using ASP.NET with C# using Visual Studio 2005.

I have a form Logging.aspx containing three user controls:

<%@ Register Src="Controls/AccidentDamage_New.ascx"
TagName="AccidentDamage_New"
    TagPrefix="uc2" %>
<%@ Register Src="Controls/Breakdown_New.ascx" TagName="Breakdown_New"
    TagPrefix="uc3" %>
<%@ Register Src="Controls/AdditionalWorks_New.ascx"
TagName="AdditionalWorks_New"
    TagPrefix="uc4" %>

These are displayed within panels:

<asp:Panel ID="pnlAccidentDamage_New" runat="server" Height="50px"
Width="100%" Visible="false">
            <uc2:AccidentDamage_New     ID="AccidentDamage_New1"
runat="server" />
        </asp:Panel>
        <asp:Panel ID="pnlBreakdown_New" runat="server" Height="50px"
Width="100%"  Visible="false">
            <uc3:Breakdown_New      ID="Breakdown_New1"
runat="server" />
        </asp:Panel>
        <asp:Panel ID="pnlAdditionalWorks_New" runat="server"
Height="50px" Width="100%"  Visible="false">
            <uc4:AdditionalWorks_New    ID="AdditionalWorks_New2"
runat="server"  />
        </asp:Panel>

I am using the panels .visible property to either display them or not.
The problem is, the code behind these thee forms executes every time.
Is there any way I can prevent this happening,

Stapes

Reply via email to