Aug 23, 2012, 4:32 PM
The control with ID 'ctl04_AddDoc' not found
HI,
I try to build a page with a ribbon style menu. So in the Ribbon I have buttons. The page is displayed and when I press the button I get the below error 500 message.
I am not sure, what I do wrong to get the Click event triggered in the ASCX code behind.
Anyone able to help with a hin?
----------------------------------------------------
The content in the ASCX page looks like this. In the last line is the onDirectClick handler
The Codebehind looks like this:
I try to build a page with a ribbon style menu. So in the Ribbon I have buttons. The page is displayed and when I press the button I get the below error 500 message.
I am not sure, what I do wrong to get the Click event triggered in the ASCX code behind.
Anyone able to help with a hin?
Server Error in '/' Application.
The control with ID 'ctl04_AddDoc' not found
Description: An unhandled exception occurred during the execution of the current web request. Please review the stack trace for more information about the error and where it originated in the code.
Exception Details: System.Web.HttpException: The control with ID 'ctl04_AddDoc' not found
Source Error:
Stack Trace:
The control with ID 'ctl04_AddDoc' not found
Description: An unhandled exception occurred during the execution of the current web request. Please review the stack trace for more information about the error and where it originated in the code.
Exception Details: System.Web.HttpException: The control with ID 'ctl04_AddDoc' not found
Source Error:
An unhandled exception was generated during the execution of the current web request. Information regarding the origin and location of the exception can be identified using the exception stack trace below. |
Stack Trace:
[HttpException (0x80004005): The control with ID 'ctl04_AddDoc' not found] Ext.Net.ResourceManager.RaisePostBackEvent(String eventArgument) +1081 System.Web.UI.Page.RaisePostBackEvent(IPostBackEve ntHandler sourceControl, String eventArgument) +13 System.Web.UI.Page.RaisePostBackEvent(NameValueCol lection postData) +176 System.Web.UI.Page.ProcessRequestMain(Boolean includeStagesBeforeAsyncPoint, Boolean includeStagesAfterAsyncPoint) +5563 |
----------------------------------------------------
The content in the ASCX page looks like this. In the last line is the onDirectClick handler
<%@ Control Language="C#" AutoEventWireup="true" CodeBehind="T2.ascx.cs" Inherits="TestExt2.Desktop.T2" %>
<%@ Register Assembly="Ext.Net" Namespace="Ext.Net" TagPrefix="ext" %>
<ext:TabPanel ID="TabPanel1" runat="server">
<Items>
<ext:Panel ID="Tab1" runat="server" Title="<%$resources: Menue_Product %>" AutoHeight="true"
BodyPadding="6">
<Content>
</Content>
</ext:Panel>
<ext:Panel ID="Tab2" runat="server" Title="Language" AutoHeight="true">
<Items>
<ext:Panel ID="Panel1" runat="server" Title="">
<TopBar>
<ext:Toolbar ID="Toolbar1" runat="server">
<Items>
<ext:ButtonGroup ID="ButtonGroup1" runat="server" Title="Clipboard" Columns="3">
<Items>
<ext:Button ID="AddDoc" runat="server" Text="<%$Resources: AddDoc %>" IconCls="add32"
Scale="Large" IconAlign="Top" Cls="x-btn-as-arrow" RowSpan="2" OnDirectClick="Click">
----------------------------------------------------The Codebehind looks like this:
namespace TestExt2.Desktop
{
public partial class T2 : System.Web.UI.UserControl
{
protected void Page_Load(object sender, EventArgs e)
{
}
protected void Click(object sender, DirectEventArgs e)
{
int a = 2;
}
}
Last edited by geraldf; Aug 23, 2012 at 4:36 PM.