Access Textbox in detail section ItemDataBound

3 posts, 0 answers
  1. Justin McMillen
    Justin McMillen avatar
    20 posts
    Member since:
    Aug 2009

    Posted 18 May 2010 Link to this post

    I'm trying to use the approach mentioned in the following article to get textbox values:

    I'm getting the following error:

    Error   1   Cannot implicitly convert type 'Telerik.Reporting.Processing.ProcessingElement' to 'Telerik.Reporting.Processing.ReportItemBase'. An explicit conversion exists (are you missing a cast?)  

    What am I doing wrong?

    private void detail_ItemDataBound(object sender, EventArgs e) 
                Telerik.Reporting.Processing.DetailSection section = sender as Telerik.Reporting.Processing.DetailSection; 
                Telerik.Reporting.Processing.ReportItemBase extraShipping = section.ChildElements.Find("extraShippingCostTextBox", false)[0]; 

  2. Peter
    Peter avatar
    1631 posts

    Posted 20 May 2010 Link to this post

    Hello Justin,

    Thank you for reporting this issue. We have updated the help article and the update will be published with the next upload of the online help. Check out the following working code snippet:

    private void detail_ItemDataBound(object sender, EventArgs e)
        Telerik.Reporting.Processing.DetailSection section = (sender as Telerik.Reporting.Processing.DetailSection);
        Telerik.Reporting.Processing.TextBox extraShipping = (Telerik.Reporting.Processing.TextBox)section.ChildElements.Find("extraShippingCostTextBox", false)[0];
        object val = section.DataObject["Weight"]; 
        if (!(val is DBNull) && (Convert.ToDecimal(val)) > 10)
            extraShipping.Visible = true;
            extraShipping.Visible = false;

    As a token of gratitude we have updated your Telerik Points.

    the Telerik team

    Do you want to have your say when we set our development plans? Do you want to know when a feature you care about is added or when a bug fixed? Explore the Telerik Public Issue Tracking system and vote to affect the priority of the items.
  3. Mohammed
    Mohammed avatar
    87 posts
    Member since:
    Aug 2011

    Posted 22 Mar 2013 Link to this post

    how can i access a textbox in a group section from data binding event of textbox in the detail section ?
Back to Top