We use cookies to give you the best experience on our website. If you continue to browse, then you agree to our privacy policy and cookie policy.
Unfortunately, activation email could not send to your email. Please try again.

How to find Panel in ItemTemplate?

Thread ID:

Created:

Updated:

Platform:

Replies:

77228 Oct 21,2008 12:27 PM Oct 27,2008 02:47 PM ASP.NET Web Forms (Classic) 1
loading
Tags: GridGroupingControl
Administrator [Syncfusion]
Asked On October 21, 2008 12:27 PM

Hi,

I am new to Syncfusion, and working on a project where we are deciding on whether to use ASP.net Grid control or Syncfusion.

We are trying to show the panel in the ItemTemplate on the button click in the row.

It would be great if you could show us how to find a control in the ItemTemplate of the GridGroupingControl.

Thanks & Regards
Rajiv Gopinath


Rajarajeswari S [Syncfusion]
Replied On October 27, 2008 02:47 PM


Hi Rajiv,

Sorry for the delay in getting back to you.

1. We are trying to show the panel in the ItemTemplate on the button click in the row:

Please refer the sample from the below link:

http://websamples.syncfusion.com/samples/Grid.Web/6.3.0.30/Grid_Web_GridInTemplate/main.htm

In the above sample:

1. Image button, GridGroupingControl is used as an ItemTemplate.
2. Clicking on the Image button changes the ImageUrl as well as load the Grid for the particular record.

2. Findout the ItemTemplate control:

ItemTemplate columns are defined using TemplateClass through code behind. By accessing the TemplateClass we can have a property to Findout the Template controls:

public class TemplateClass : ITemplate
{
private Control m_ctrlChildControl = null;
public Control childControl
{
get
{
return m_ctrlChildControl;
}
set
{
m_ctrlChildControl = value;
}
}
public TemplateClass(Control ctrlChildControl)
{
m_ctrlChildControl = ctrlChildControl;
}

public void InstantiateIn(Control container)
{
container.Controls.Add(m_ctrlChildControl);
}
}

TemplateClass temp = this.GridGroupingControl1.TableDescriptor.Columns[2].ItemTemplate;
Control cntrl = temp.childControl;

Please let me know if you have any other concerns.

Regards,
Raji



CONFIRMATION

This post will be permanently deleted. Are you sure you want to continue?

Sorry, An error occured while processing your request. Please try again later.

You are using an outdated version of Internet Explorer that may not display all features of this and other websites. Upgrade to Internet Explorer 8 or newer for a better experience.

;