Telerik Forums
UI for ASP.NET AJAX Forum
3 answers
138 views

Hi,

I am not able to trigger the "OnClientNodeDropping"  event when a parent node is dropped onto a child node. This is required in order to execute some custom code for cloning the parent node and adding it as a child. In the attached example, I have had to use a customised picker tool to add the parent node "Everyone" to its child "My Team". This is fine for a example, but not a practical solution.

I have tried using the method described in the below link to get the target node that the parent is dropped onto. However this will not give me the target node attributes only the html element of the node.
http://www.telerik.com/community/forums/aspnet-ajax/treeview/dropping-a-node-on-itself-doesn-t-fire-events.aspx

Am I missing an attribute in the Telerik control ? (I have both EnableDragAndDrop and EnableDragAndDropBetweenNodes set to true), or is there something else I should be doing?

Thanks
Justin

Boyan Dimitrov
Telerik team
 answered on 13 Jun 2013
1 answer
123 views
Recently we have upgraded our Telerik Web dll's i.e. Telerik.Web.Design.dll,Telerik.Web.UI.dll,Telerik.Web.UI.Skins.dll from 2011.3.1115.40 version to newer version 2013.1.410.40. in our development environment it is working fine.
But when these dlls were replaced in QA Environment the css and images were missing for some time and later they got updated automatically and everything was working fine as if there is no issue.

This is a typical scenario because we tried to delete the temporary files, browser cookies and all that can be done but still the issue was existing but later when we checked everything went well. This happened in QA but we don't want this to be repeated in Production Environment for that we need a best posssible solution so that we know what needs to be done beforehand this issue does not repeat.

Awaiting for the quick response on this.

Thanks

O'Man
Top achievements
Rank 1
 answered on 13 Jun 2013
0 answers
42 views
This is a duplicate post of this one. I don't know how it happened...
Please delete.
Mauro
Top achievements
Rank 1
 asked on 13 Jun 2013
3 answers
615 views
I have two grid with same number and type of columns. The number of rows are also same.
Only difference is the content of the grids.
Basically I want to show the difference in two grids for each column.
I want to show first column from both the grids, then second column from both the grids and so on.
How I can achieve this?
Princy
Top achievements
Rank 2
 answered on 13 Jun 2013
3 answers
379 views
Is it possible to export a RadGrid to Excel so that it's page orientation is Landscape and that it's print setting is also Landscape?
Kostadin
Telerik team
 answered on 13 Jun 2013
1 answer
105 views
I want to drag and drop from a RadListBox To another RadListBox in a table ?

and persist this server side but it not works :

My .cs :

protected void Page_Load(object sender, EventArgs e)
        {
            // Total number of rows.
            int rowCnt = 4;
            // Current row count.
            int rowCtr;
            // Total number of cells per row (columns).
            int cellCtr;
            // Current cell counter
            int cellCnt = 7;

           // rowCnt = int.Parse(TextBox1.Text);
           // cellCnt = int.Parse(TextBox2.Text);

            for (rowCtr = 1; rowCtr <= rowCnt; rowCtr++)
            {
                // Create new row and add it to the table.

                HtmlTableRow tRow = new HtmlTableRow();
                Table1.Rows.Add(tRow);
                for (cellCtr = 1; cellCtr <= cellCnt; cellCtr++)
                {
                    // Create a new cell and add it to the row.
                    HtmlTableCell tCell = new HtmlTableCell();
                   // tCell.Text = "Row " + rowCtr + ", Cell " + cellCtr;
                    RadListBox rr = new RadListBox();
                    rr.ItemTemplate = new RadListBoxTemplate();
                    rr.SelectionMode = ListBoxSelectionMode.Multiple;
                    rr.AllowReorder =true;
                    rr.AutoPostBackOnReorder =true;
                    rr.EnableDragAndDrop =true;
                   
                    List<int> i = new List<int>();
                    i.Add(1);
                    i.Add(2);
                    i.Add(3);
                    rr.DataSource = i;
                    rr.DataBind();
                    tCell.Controls.Add(rr);
                    tRow.Cells.Add((tCell));
                }
            }
        }
        ////
        class RadListBoxTemplate : ITemplate
        {
            public void InstantiateIn(Control container)
            {
                Label id = new Label();
                id.ID = "idLabel";
                id.CssClass = "idClass";
                id.DataBinding += new EventHandler(id_DataBinding);
                container.Controls.Add(id);
                Label name = new Label();
                name.ID = "nameLabel";
                name.CssClass = "list";
                name.DataBinding += new EventHandler(name_DataBinding);
                container.Controls.Add(name);
                HyperLink details = new HyperLink();
                details.ID = "details";
                details.CssClass = "list";
                details.Text = "Details";
                details.DataBinding += new EventHandler(details_DataBinding);
                container.Controls.Add(details);
            }
            private void id_DataBinding(object sender, EventArgs e)
            {
                //Label target = (Label)sender;
                //RadListBoxItem item = (RadListBoxItem)target.BindingContainer;
                //string id = Convert.ToString((int)DataBinder.Eval(item.DataItem, "ID"));
                //target.Text = id;
            }
            private void name_DataBinding(object sender, EventArgs e)
            {
                //Label target = (Label)sender;
                //RadListBoxItem item = (RadListBoxItem)target.BindingContainer;
                //string name = (string)DataBinder.Eval(item.DataItem, "Name");
                //target.Text = name;
            }
            private void details_DataBinding(object sender, EventArgs e)
            {
                //HyperLink target = (HyperLink)sender;
                //RadListBoxItem item = (RadListBoxItem)target.BindingContainer;
                //string id = Convert.ToString((int)DataBinder.Eval(item.DataItem, "ID"));
                //target.NavigateUrl = "Details.aspx?ID=" + id;
            }
        }
My .aspx like this :

  <telerik:RadScriptManager runat="server" ID="RadScriptManager1" />
    <telerik:RadAjaxPanel ID="RadAjaxPanel1" runat="server" CssClass="example-panel">
        <telerik:RadListBox ID="RadListBox1" CssClass="RadListBox1" runat="server" Width="200px"
            Height="200px" SelectionMode="Multiple" AllowTransfer="true" AutoPostBackOnTransfer="true"
            AllowReorder="true" AutoPostBackOnReorder="true" EnableDragAndDrop="true" Skin="Office2010Blue"
            OnDropped="RadListBox1_Dropped" OnDropping="RadListBox1_Dropping" OnTransferring="RadListBox1_Transferring">
            <Items>
                <telerik:RadListBoxItem Text="Argentina"></telerik:RadListBoxItem>
                <telerik:RadListBoxItem Text="Australia"></telerik:RadListBoxItem>
                <telerik:RadListBoxItem Text="Brazil"></telerik:RadListBoxItem>
                <telerik:RadListBoxItem Text="Canada"></telerik:RadListBoxItem>
                <telerik:RadListBoxItem Text="Chile"></telerik:RadListBoxItem>
                <telerik:RadListBoxItem Text="China"></telerik:RadListBoxItem>
                <telerik:RadListBoxItem Text="Egypt"></telerik:RadListBoxItem>
                <telerik:RadListBoxItem Text="England"></telerik:RadListBoxItem>
                <telerik:RadListBoxItem Text="France"></telerik:RadListBoxItem>
                <telerik:RadListBoxItem Text="Germany"></telerik:RadListBoxItem>
                <telerik:RadListBoxItem Text="India"></telerik:RadListBoxItem>
                <telerik:RadListBoxItem Text="Indonesia"></telerik:RadListBoxItem>
                <telerik:RadListBoxItem Text="Kenya"></telerik:RadListBoxItem>
                <telerik:RadListBoxItem Text="Mexico"></telerik:RadListBoxItem>
                <telerik:RadListBoxItem Text="New Zealand"></telerik:RadListBoxItem>
                <telerik:RadListBoxItem Text="South Africa"></telerik:RadListBoxItem>
            </Items>
        </telerik:RadListBox>
        <table id="Table1" runat="server" rules="Both">
        </table>
    </telerik:RadAjaxPanel>
Nencho
Telerik team
 answered on 13 Jun 2013
1 answer
97 views
I am having a big problem here. I have a class lib and a user control in there but I can not use the telerik intellisense the .ascx file. I did everything here http://www.telerik.com/community/forums/aspnet-mvc/general/cannot-use-telerik-intellisense-in-razor-views-when-these-views-are-in-class-library.aspx but this is not working. I have asp:.. intellisense but no intellisense for the telerik dll. Plese help me with this because It is a real stopper for me. Here is my web config file that I am placing in the class lib root and in the folder where is my user control. I also added the Telerik.Web.UI.dll to the GAC

<?xml version="1.0"?>
<configuration>
  <system.web>
    <compilation>
      <assemblies>
        <add assembly="Telerik.Web.UI, Version=2012.3.1308.40, Culture=neutral, PublicKeyToken=121fae78165ba3d4"/>
      </assemblies>
    </compilation>
    <pages>
      <controls>
        <add tagPrefix="asp" namespace="System.Web.UI" assembly="System.Web.Extensions, Version=4.0.0.0, Culture=neutral, PublicKeyToken=31BF3856AD364E35"/>
        <add tagPrefix="asp" namespace="System.Web.UI.WebControls" assembly="System.Web.Extensions, Version=4.0.0.0, Culture=neutral, PublicKeyToken=31BF3856AD364E35"/>
        <add tagPrefix="telerik" namespace="Telerik.Web.UI" assembly="Telerik.Web.UI, Version=2012.3.1308.40, Culture=neutral, PublicKeyToken=121fae78165ba3d4"/>
      </controls>
      <namespaces>
        <add namespace="Telerik.Web.UI" />
      </namespaces>
    </pages>
  </system.web>
</configuration>

Please give me the exact steps that I should do.
ivan
Top achievements
Rank 1
 answered on 13 Jun 2013
2 answers
84 views
Hello,

I have the following RadGrid with a RadEditor embedded in it.  Everything works as expected, except when I change the color of the text in a RadEditor row, I am not able to add another row.  I don' receive any errors and I am able to  step through the btnAddInstruction_Click and grdInstructions_ItemDataBound events without any issues.  It just will not render another row.



btnAddInstruction_Click Code:
public static void AddInstructionGridRow(RadGrid gridName)
            {
                bool instructionIsNull = false;
                ProjectInstruction projectInstruction;
                List<ProjectInstruction> projectInstructions = new List<ProjectInstruction>();
                RadEditor txtInstruction;

                //  Iterate through the grid rows and retain all previously entered data.
                foreach (GridDataItem gridRow in gridName.Items)
                {
                    //  Create new Project Instruction object.
                    projectInstruction = new ProjectInstruction();

                    // Project ID (Hidden)
                    HiddenField hdnProjectID = gridRow.FindControl("hdnProjectID") as HiddenField;
                    if (hdnProjectID != null)
                    {
                        projectInstruction.ProjectID = Convert.ToInt32(hdnProjectID.Value);
                    }
                    else
                    {
                        projectInstruction.ProjectID = 0;
                    }

                    // Project Instruction ID (Hidden)
                    HiddenField hdnProjectInstructionID = gridRow.FindControl("hdnProjectInstructionID") as HiddenField;
                    if (hdnProjectInstructionID != null)
                    {
                        projectInstruction.ID = Convert.ToInt32(hdnProjectInstructionID.Value);
                    }
                    else
                    {
                        projectInstruction.ID = 0;
                    }

                    //  Project Instruction
                    txtInstruction = gridRow.FindControl("txtInstruction") as RadEditor;
                    if (txtInstruction.Content.Trim().Length == 0)
                    {
                        instructionIsNull = true;
                    }
                    projectInstruction.Instruction = txtInstruction.Content;

                    //  Add Project Instruction to Project Instructions object.
                    projectInstructions.Add(projectInstruction);
                }

                //  Create new Project Instruction object.
                if (!instructionIsNull)
                {
                    projectInstructions.Add(AddProjectInstruction());
                }

                //  Update Project Instructions grid.
                gridName.DataSource = projectInstructions;
                gridName.Rebind();
            }

grdInstructions_ItemDataBound
 protected void grdInstructions_ItemDataBound(object sender, GridItemEventArgs e)
        {
            if (e.Item.ItemType == GridItemType.Item || e.Item.ItemType == GridItemType.AlternatingItem)
            {
                //  Current row object.
                ProjectInstruction projectInstruction = (ProjectInstruction)e.Item.DataItem;
                string referenceNumber = string.Empty;

                //  Row Number
                GridDataItem dataItem = (GridDataItem)e.Item;
                referenceNumber = Convert.ToString(e.Item.ItemIndex + 1);
                dataItem["ReferenceNumber"].Text = referenceNumber;

                //  Project Instruction
                RadEditor txtInstruction = e.Item.FindControl("txtInstruction") as RadEditor;
                txtInstruction.Content = projectInstruction.Instruction;
                //txtInstruction.Languages.Add(new SpellCheckerLanguage("en-US", "English"));

                //  Delete Column               
                GridDataItem item = e.Item as GridDataItem;
                //  Display Delete option when adding new record and if there is more then one row.
                if (grdInstructions.MasterTableView.Items.Count > 0)
                {
                    //  Show Delete column during Add.
                    item["btnDeleteInstructionRow"].Controls[0].Visible = true;
                    item["btnDeleteInstructionRow"].Attributes["onclick"] = "return confirm('Delete Instruction# " +  referenceNumber + "?')";
                }
                else
                {
                    //  Hide Delete option if there is only one row.
                    item["btnDeleteInstructionRow"].Controls[0].Visible = false;
                }
            }
        }

Can you please tell  me what is causing another row not to be rendered when HTML color formatting is applied to the text in a RadEditor row?

Thank Very Much in Advance!
Pavlina
Telerik team
 answered on 13 Jun 2013
1 answer
88 views
In chrome the styles are off on some of the skins

- Silk the close x is not centered in the circle
- metro the callout doesn't look like it belongs, kinda hangs out the top a bit
Bozhidar
Telerik team
 answered on 13 Jun 2013
1 answer
135 views
Is it possible for me to populate a dropdown menu with the column names from my radgrid and use the dropdown menu to sort the grid (along with radio buttons to select ascending or descending), as opposed to using column headers to sort?
Princy
Top achievements
Rank 2
 answered on 13 Jun 2013
Narrow your results
Selected tags
Tags
+? more
Top users last month
Simon
Top achievements
Rank 2
Iron
Iron
Bob
Top achievements
Rank 3
Iron
Iron
Veteran
Marco
Top achievements
Rank 4
Iron
Iron
Iron
Grant
Top achievements
Rank 3
Iron
Iron
Iron
Kao Hung
Top achievements
Rank 1
Iron
Want to show your ninja superpower to fellow developers?
Top users last month
Simon
Top achievements
Rank 2
Iron
Iron
Bob
Top achievements
Rank 3
Iron
Iron
Veteran
Marco
Top achievements
Rank 4
Iron
Iron
Iron
Grant
Top achievements
Rank 3
Iron
Iron
Iron
Kao Hung
Top achievements
Rank 1
Iron
Want to show your ninja superpower to fellow developers?
Want to show your ninja superpower to fellow developers?