Skip Navigation LinksHome / Community & Support / Developer Productivity Tools Forums / ASP.NET > Grid > WELCOME TO THE TELERIK SUPPORT FORUMS (IMPORTANT INSTRUCTIONS)
RadControls for ASP.NET are no longer supported (see this page for reference). In case you have inquiries about the Telerik ASP.NET AJAX controls, post them in the pertinent ASP.NET AJAX forums.

WELCOME TO THE TELERIK SUPPORT FORUMS (IMPORTANT INSTRUCTIONS)

Feed from this thread
  • Posted on Feb 17, 2006 (permalink)

    The aim of the Telerik Support Forum is to provide all registered users a way to find answers to their questions before contacting Telerik. You can also use them to:

    • discuss coding techniques with fellow Telerik users
    • share your experience on the Telerik suite of controls
    • contact Telerik with a question
    • ask general questions, not related to Telerik controls
    • contact Telerik's MVPs
    • help other users.

    A post in the Support Forums doesn't guarantee you a response from the Telerik support team although 95% of all posts are eventually answered. Additionally, a post is not assigned a response time as with the support ticketing system. In case you need a faster and precise response, please start a new support ticket as it gets higher priority than Forum posts.

    Telerik strives to constantly improve its support services but it is essential to have full information so as to supply precise replies. It is important that you follow the guidelines below in order to receive an accurate response:

    GUIDELINES TO USING THE SUPPORT FORUM

    1. You should have a valid Telerik account to post in the Forum. You can create one from the Client.NET intranet. Anonymous names will not be allowed and such posts will not be answered or will be deleted.
    2. Use the relevant product forum to post your questions and comments. If your question relates to two or more Telerik products, you can post it in the RadControls section.
    3. File attachments are not supported. You can, however, paste a code snippet. If you think that Telerik needs to review your project and/or files, or that a screenshot is necessary, start a new support ticket.
    4. Describe your question in detail.
    5. State the development software you are using, including:
      • ASP.NET version
      • OS
      • exact browser version
      • exact version of the Telerik product
      • preferred programming language (VB.NET or C#)
    6. Provide step by step instructions on how to reproduce erroneous behavior.
    7. If applicable, send us the error you are receiving.
    8. Telerik reserves the right to use, reproduce and share the material you post within the forums.
    9. Telerik reserves the right to not participate in all posts.
    10. Telerik reserves the right to remove any messages that do not comply with these terms.

    ENJOY!!!

    Best Wishes
    the Telerik team

  • Posted on Mar 13, 2007 (permalink)

    dear sir

    i create a dynamic grid with a dynamic columns ,

    i use  a template column  as followin 




    private class MyTemplate : ITemplate

    {

    protected CheckBoxList chkbClients;

    protected Label lControl;

    //protected CheckBox boolValue;

    private string colname;

    private string colClientname;

    public MyTemplate(string columnname, string columnClientname)

    {

    colname = columnname;

    colClientname = columnClientname;

    }

    public void InstantiateIn(System.Web.UI.Control container)

    {

    chkbClients = new CheckBoxList();

    chkbClients.ID = "chkbClients" + colname;

    chkbClients.DataBinding += new EventHandler(chkbClients_DataBinding);

    lControl = new Label();

    lControl.ID = "lControl" + colname;

    lControl.CssClass = "'visibility:hidden'";

    ClientsData clientData;

    clientData = Clients.getAllClients(Languages.Arabic.ToString());

     

    chkbClients.DataSource = clientData.Client;

    chkbClients.DataTextField = "ClientNameE";

    chkbClients.DataValueField = "ClientID";

    chkbClients.Width = 200;

    Table table = new Table();

    TableRow row1 = new TableRow();

    TableCell cell13 = new TableCell();

    TableCell cell14 = new TableCell();

    row1.Cells.Add(cell13);

    row1.Cells.Add(cell14);

    table.Rows.Add(row1);

    cell13.Controls.Add(chkbClients);

    cell13.CssClass = "width:10px; height:10px; overflow:scroll;";

    cell14.Controls.Add(lControl);

    cell14.Visible = false;

    container.Controls.Add(table);

    }

    void boolValue_DataBinding(object sender, EventArgs e)

    {

    CheckBox cBox = (CheckBox)sender;

    GridDataItem container = (GridDataItem)cBox.NamingContainer;

    if (((DataRowView)container.DataItem) == null)

    {

    return;

    }

    bool btemp = false;

    if (int.Parse(((DataRowView)container.DataItem)["col1"].ToString()) > 0)

    {

    btemp = true;

    }

    cBox.Checked = btemp;

    }

     

    public void chkbClients_DataBinding(object sender, EventArgs e)

    {

    CheckBoxList chkbClients = (CheckBoxList)sender;

    //chkbClients.DataBind();

     

     

    GridDataItem container = (GridDataItem)chkbClients.NamingContainer;

    if (container == null)

    {

    return;

    }

    string clientIds = "";

    clientIds = ((DataRowView)container.DataItem)[colClientname].ToString();

    clientIds += ",";

    lControl.Text = clientIds;

     

     

    }

    }//class



    and i use it  im my code

    private void GenerateColyumns()

    {

    DataTable jp = journeyPlanData.Tables["JourneyPlan"];

    foreach (DataColumn col in jp.Columns)

    {

    if (col.ColumnName.IndexOf("colClient")>=0)

    {

    string colId = col.ColumnName.Substring(9, col.ColumnName.Length - 9);

    string templateColumnName = "col" + colId;

    GridTemplateColumn templateColumn = new GridTemplateColumn();

    templateColumn.ItemTemplate = new MyTemplate("col" + colId, "colClient" + colId);

    templateColumn.HeaderText = "Day " + colId;

    templateColumn.UniqueName = templateColumnName;

    templateColumn.AllowFiltering = false;

    grdJPs.MasterTableView.Columns.Add(templateColumn);

    }

    }

    }






    then i add a button to loop for all rows in the grid and get the controls (check box list ) from the grid cell

    how can i loop for all rows and columns to get the chec box list control from every cell ?????

  • Sebastian Sebastian admin's avatar

    Posted on Mar 13, 2007 (permalink)

    Hi Hani,

    This thread is devoted to serve to provide some guidance to the telerik community about how to post support tickets/forum posts (separated in steps). For specific inquiries I should ask you start a new forum post/support ticket from your Client.net account and explain the issue in the corresponding thread. We will continue our communication through that thread - simply paste the information/code snippets in it.

    Some preliminary pointers - you can loop through the Items collection of the grid (holding every grid data item) and find the checkboxes invking FindControl(id) method for each row.

    Best regards,
    Stephen
    the telerik team

  • umacg avatar

    Posted on May 4, 2007 (permalink)

    I have onRowselecting event on my grid. I am displaying a confirm message in this function. If user selects "Cancel", I am returning false. But still it is firing server side events like SelectedIndexChanged and ItemCommand. Can you please explain me how to control the execution of serverside events in onrowselecting event of a grid.
    -Uma

  • surfer Master avatar

    Posted on May 5, 2007 (permalink)

    Are you by any chance using Ajax for the grid? This may have some effect no confirm dialogs, based on certain situations.

    In any case, I believe the following online help article

    Confirmation dialogs in rad Grid
    http://www.telerik.com/help/aspnet/grid/grdConfirmationDialogs.html

    provides additional insight and sample code how to achieve this setup.

Back to Top

Skip Navigation LinksHome / Community & Support / Developer Productivity Tools Forums / ASP.NET > Grid > WELCOME TO THE TELERIK SUPPORT FORUMS (IMPORTANT INSTRUCTIONS)