Telerik Forums
UI for ASP.NET AJAX Forum
1 answer
179 views
Hi,

I am dynamically creating the 'GridNumericColumn' Columns in the Grid.By using "DataFormatString" property I am convering to currency, Percentage formats. I am able to see the "$" and "%" symbol in Grid. But in the Excel sheet (after exporting Grid to Excel), those symbols are missing. Could anybody suggest me what would be the problem?

Thanks,
Malli
Pavlina
Telerik team
 answered on 13 Nov 2009
2 answers
389 views
I've been searching around the examples and the threads in this forum to find a solution to my problem, so now i'll try to start a new thread and hopefully get a workaround/solution.

I have a RadComboBox that is bound in the itemrequsted event. The combobox has an itemtemplate with a serverside ASP button control. What i want to do is, when a user clicks the button, the item gets deleted. Here is the code for the combobox


 <telerik:RadCombobox  
                            ID="ReportCombobox"  
                            HighlightTemplatedItems="True" 
                            DataTextField="Title" 
                            EnableLoadOnDemand="True" 
                            Text="Vælg eksisterende rapport" 
                            LoadingMessage="Henter rapporter" 
                            DataValueField="ReportGUID" 
                            Width="180px" 
                            runat="server"  
                            AutoPostBack="True" SkinsPath="~/RadControls/ComboBox/Skins"> 
                            <HeaderTemplate> 
                                <table width="400" cellpadding="0" cellspacing="0" border="0"> 
                                    <tr> 
                                        <td style="width:230;" class="ReportDropDownTitleHead">Rapport titel</td> 
                                        <td style="width:140;" class="ReportDropDownDateHead">Oprettet</td> 
                                        <td style="width:80;" class="ReportDropDownUsernameHead">Oprettet af</td> 
                                        <td style="width:80;" class="ReportDropDownUsernameHead">Org ID</td> 
                                        <td style="width:80;" class="ReportDropDownUsernameHead">Slet rapport</td> 
                                    </tr> 
                                </table> 
                            </HeaderTemplate> 
                            <ItemTemplate> 
                             
                                <table width="350" cellpadding="0" cellspacing="0" border="0"> 
                                    <tr> 
                                        <td style="width:230;" class="ReportDropDownTitleColumn"> 
                                            <%# DataBinder.Eval(Container.DataItem, "Title") %> 
                                         </td> 
                                        <td style="width:140;" class="ReportDropDownDateColumn"> 
                                            <%# DataBinder.Eval(Container.DataItem, "Date") %> 
                                         </td> 
                                        <td style="width:80;" class="ReportDropDownUsernameColumn"> 
                                            <%# DataBinder.Eval(Container.DataItem, "Username") %> 
                                         </td> 
                                         <td style="width:80;" class="ReportDropDownUsernameColumn"> 
                                            <%# DataBinder.Eval(Container.DataItem, "MunicipalityIdentifier")%> 
                                         </td> 
                                         <td> 
                                         <div onclick="StopPropagation(this)" > 
                                         <asp:Button  runat="server" ID="btnDelete" Visible='<%# showDeleteButton(DataBinder.Eval(Container.DataItem, "CVR").ToString())%>'  OnClientClick="OnClientSelectedIndexChanging()"  Text="X" ToolTip="Slet Rapport" /> 
                                        </div> 
                                        </td> 
                                    </tr> 
                                </table> 
                                
                            </ItemTemplate> 
                        </telerik:RadCombobox> 

The  Javascripts

<script type="text/javascript"> 
 
    var combobox = null; 
    function pageLoad() 
     { 
         combobox = $find("<%= ReportCombobox.ClientID %>"); 
         alert(combobox.get_value()); 
    } 
    function StopPropagation(e) { 
        //cancel bubbling 
       alert("stoppropapagtion"); 
        e.cancelBubble = true; 
        if (e.stopPropagation) { 
            e.stopPropagation(); 
        } 
    } 
 
    function OnClientSelectedIndexChanging()  
    { 
        var isConfirm = true; 
        isConfirm = confirm("Vil du slette rapporten?"); 
        if (isConfirm) { 
            var combo = $find("<%= ReportCombobox.ClientID %>"); 
            var hiddenGUID = combo.get_value(); 
            document.getElementById("<%=hiddenbox.ClientID%>").value = hiddenGUID; // "hest"; //item.get_value(); 
            alert(hiddenGUID); 
        } 
        return false; 
 
    } 
     
     
        </script> 

I have two problems now:

1. When i click on the deletebutton first time, the value of the combobox is empty, second time the value is set correct and the item gets deleted. Same thing happends for the next item i try to delete, first time hiddenGUI has the value of the previous item and second time the value is correct.

2. The StopPropagation function is fired correctly as i see the alertbox, but the item is still loaded even though it should only fire the event of the button, and not the item iteself.

I've tried with ASP.NET AJAX 2008 version 1.5.27 and the latest release from november 2009, theres no change. 
I also tried to add a pageLoad javascript function to see if the combo has any value after all controls are loaded, but its also empty. 
Yana
Telerik team
 answered on 13 Nov 2009
1 answer
82 views
in my page there are 2 text boxes and then the RadEditor is coming. I set the Tab Index for the textboxes 1,2 respectively in order and for the Rad Editor set the Tab Index as 3. If I click tab in the second text box the icon is not in the rad Editor content. It just applied for the whole Rad Editor. We need to get the icon in the content. Please provide a solution
Rumen
Telerik team
 answered on 13 Nov 2009
1 answer
159 views
I have added to VisualStudio 2008 Rad Control. When I open the new 3.5 project toolbox does not appear on project .
Edward
Top achievements
Rank 1
 answered on 13 Nov 2009
1 answer
138 views
I have a simple site map file:
<?xml version="1.0" encoding="utf-8" ?> 
<siteMap xmlns="http://schemas.microsoft.com/AspNet/SiteMap-File-1.0" > 
    <siteMapNode url="" title=""  description=""> 
      <siteMapNode title="First item"> 
        <siteMapNode url="~/Page1.aspx" title="Page 1"  description="" /> 
        <siteMapNode url="~/Page2.aspx" title="Page 2"  description="" /> 
      </siteMapNode> 
      <siteMapNode title="Second item"> 
        <siteMapNode url="~/Page3.aspx" title="Page 3"  description="" /> 
      </siteMapNode> 
    </siteMapNode> 
</siteMap> 
 


A simple sitemap data source is added to the page

A radmenu is binded to that data source...

<%@ Master Language="C#" AutoEventWireup="true" CodeBehind="Site.master.cs" Inherits="WebApplication1.Site" %> 
 
<%@ Register Assembly="Telerik.Web.UI" Namespace="Telerik.Web.UI" TagPrefix="telerik" %> 
 
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"> 
 
<html xmlns="http://www.w3.org/1999/xhtml" > 
<head runat="server"> 
    <title></title> 
    <asp:ContentPlaceHolder ID="head" runat="server"> 
    </asp:ContentPlaceHolder> 
</head> 
<body> 
    <form id="form1" runat="server"> 
    <telerik:RadScriptManager ID="RadScriptManager1" Runat="server"> 
    </telerik:RadScriptManager> 
    <telerik:RadMenu ID="RadMenu1" runat="server" Width="100%" DataSourceID="SiteMapDataSource1"> 
    </telerik:RadMenu> 
    <asp:SiteMapDataSource ID="SiteMapDataSource1" runat="server" ShowStartingNode="false" /> 
    <div> 
        <asp:ContentPlaceHolder ID="ContentPlaceHolder1" runat="server"> 
         
        </asp:ContentPlaceHolder> 
    </div> 
    </form> 
</body> 
</html> 
 


now, everytime I go to Page1.aspx the "First Time" and "Page 1" node in my radmenu are highlighted (as expected) because that is the current location returned by the sitemapdatasource1

How could I avoid this behaivor? I don't want to highlight the current page in the radmenu, I guess this should be something I just don't know how to do...

Could somebody help me please?

PD: ASP.NET RadControls 2009 Q2
Peter
Telerik team
 answered on 13 Nov 2009
1 answer
103 views
I am trying to format a rad menu to have the same style as the menu on this page: http://www.missionfoodsfsc.com/Products/Default.aspx.

I have set the flow to horizontal like it says to on the telerik.com support page for rad menu but I'm not having any luck.  This is what I have in my code so far: 
<dnn:RadMenu runat="server" ID="dnnRADMENU" GroupExpandDirection="Down" Flow="Horizontal" CssClass="header-wrap-content-radmenu-wrap-content"
                  ExpandAnimationType="OutExpo" Height="63" ExpandAnimationDuration="500" CollapseAnimationType="inexpo"
                    CollapseAnimationDuration="300" ShowPath="true" SelectedPathHeaderItemCss="focusedItem"
                    EnableEmbeddedSkins="false" />

What am I doing wrong?

Thanks in advance for any help!
Andrea
Paul
Telerik team
 answered on 13 Nov 2009
1 answer
175 views
Hi all,

Hopefully someone can help me with this.  I have a page i am building that conatins a RadTreeView and a RadTabStrip.  For some reason the Tabs are rendering as a list instead of displaying horizontally across the screen.  When i remove the treeview the tabs display correctly.

Here is a sample of what Im trying to do:-

<table style="font-family:Verdana;font-size:8pt;">  
        <tr> 
            <td> 
                <telerik:RadTreeView Width="400px"  Enabled="true" CausesValidation="true"   
                  ID="RadTreeView1" runat="server">  
                      
                </telerik:RadTreeView>     
            </td> 
            <td valign="top" style="margin-left:15px;">  
                <telerik:RadTabStrip ID="RadTabStrip1" runat="server" 
                    MultiPageID="Multipage1"  SelectedIndex="0" >                       
                    <Tabs>   
                        <telerik:RadTab  Text="Hierarchy Details">  
                        </telerik:RadTab>                         
                        <telerik:RadTab Text="Organisation Details"  Selected="True"  > 
                        </telerik:RadTab> 
                        <telerik:RadTab Text="Interested Parties" > 
                        </telerik:RadTab> 
                        <telerik:RadTab Text="Controlling Organisations" > 
                        </telerik:RadTab> 
                        <telerik:RadTab Text="Associations">  
                        </telerik:RadTab> 
                    </Tabs> 
                </telerik:RadTabStrip>   
                <telerik:RadMultiPage runat="server" ID="Multipage1" SelectedIndex="0" > 
                    <telerik:RadPageView ID="RadPageView1"  runat="server">Page 1</telerik:RadPageView> 
                    <telerik:RadPageView ID="RadPageView2" runat="server">Page 2</telerik:RadPageView> 
                    <telerik:RadPageView ID="RadPageView3" runat="server">Page 3</telerik:RadPageView> 
                    <telerik:RadPageView ID="RadPageView4" runat="server">Page 4</telerik:RadPageView> 
                    <telerik:RadPageView ID="RadPageView5" runat="server">Page 5</telerik:RadPageView> 
                </telerik:RadMultiPage> 
            </td> 
        </tr> 
    </table> 

Any help is greatly appreciated,

Regards,

Denys
Paul
Telerik team
 answered on 13 Nov 2009
3 answers
90 views
I would like to open a RadWindow and have its contents be an entry form from another website. In this scenario I need to pass data to this website as well as get data back once the user submits the data entry form. I am familiar with using Form Posts with an Action value and hidden field values but I was wondering if this functionality is possible using a RadWindow?

My goal is to provide a modal window so I"ll have some control what the user can do once they get to this seperate website to fill out the entry form. In other words, I'd like to avoid the possibility that the user will navigate somewhere completely different once they get to the entry form page and I'm hoping a Modal RadWindow will do the trick.

I hope this makes sense and if the RadWindow is not the solution, can anyone suggest some other solution that could perform similar functionality.

Michael
mbd
Top achievements
Rank 1
 answered on 13 Nov 2009
4 answers
242 views
I am using Q1 2009 release of the ASP.NET Ajax toolset. I have created a toolbar and when I attempt to set a Navigate URL with a specified target, the Navigate works great but it opens in both the parent window and the new window. Am I doing something wrong here!?

            <telerik:RadToolBar ID="tbTicketDetails" runat="server" Width="100%" AutoPostBack="true">  
                <Items> 
                    <telerik:RadToolBarButton runat="server" Text="Add Notes" ImageUrl="~/Images/notebook_pencil.png" 
                        Value="AddNotes" CommandName="AddNotes" OnLoad="GetItemURL">  
                    </telerik:RadToolBarButton> 
                    <telerik:RadToolBarButton runat="server" Text="Close" ImageUrl="~/Images/door.png" 
                        Value="CloseTicket" CommandName="CloseTicket" OnLoad="GetItemURL">  
                    </telerik:RadToolBarButton> 
                    <telerik:RadToolBarButton runat="server" Text="Lock" ImageUrl="~/Images/lock.png" 
                        Value="LockTicket" CommandName="LockTicket">  
                    </telerik:RadToolBarButton> 
                    <telerik:RadToolBarButton runat="server" Text="Unlock" ImageUrl="~/Images/lock_unlock.png" 
                        Value="UnlockTicket" CommandName="UnlockTicket">  
                    </telerik:RadToolBarButton> 
                    <telerik:RadToolBarButton runat="server" Text="Claim Ticket" CommandName="ClaimTicket" 
                        ImageUrl="~/Images/card_claimticket.png" Value="ClaimTicket">  
                    </telerik:RadToolBarButton> 
                    <telerik:RadToolBarButton runat="server" Text="Release Ticket" CommandName="ReleaseTicket" 
                        ImageUrl="~/Images/card_releaseticket.png" Value="ReleaseTicket">  
                    </telerik:RadToolBarButton> 
                    <telerik:RadToolBarButton runat="server" Text="Assign Ticket" CommandName="AssignTicket" 
                        ImageUrl="~/Images/card__assignticket.png" Value="AssignTicket" OnLoad="GetItemURL">  
                    </telerik:RadToolBarButton> 
                    <telerik:RadToolBarButton runat="server" Text="Move Ticket" CommandName="MoveTicket" 
                        ImageUrl="~/Images/pin_moveticket.png" Value="MoveTicket" OnLoad="GetItemURL">  
                    </telerik:RadToolBarButton> 
                    <telerik:RadToolBarButton runat="server" Text="Reopen Ticket" CommandName="ReopenTicket" 
                        Value="ReopenTicket" ImageUrl="~/Images/reopenticket.png" OnLoad="GetItemURL" /> 
                    <telerik:RadToolBarButton runat="server" Text="Delete Ticket" CommandName="DeleteTicket" 
                        ImageUrl="~/Images/delete.png" Value="DeleteTicket">  
                    </telerik:RadToolBarButton> 
                    <telerik:RadToolBarButton runat="server" Text="Restore Ticket" CommandName="RestoreTicket" 
                        ImageUrl="~/Images/restore.png" Value="RestoreTicket">  
                    </telerik:RadToolBarButton> 
                    <telerik:RadToolBarButton runat="server" Text="Edit Ticket Details" CommandName="EditDetails" 
                        ImageUrl="~/Images/ticket_pencil.png" Value="EditDetails" Visible="false" OnLoad="GetItemURL">  
                    </telerik:RadToolBarButton> 
                    <telerik:RadToolBarButton runat="server" Text="Assign Goal" CommandName="AssignGoal" 
                        ImageUrl="~/Images/accreditationgoal.png" Value="AssignGoal" OnLoad="GetItemURL">  
                    </telerik:RadToolBarButton> 
                    <telerik:RadToolBarButton runat="server" IsSeparator="true"></telerik:RadToolBarButton> 
                    <telerik:RadToolBarButton runat="server" Text="Print" CommandName="PrintWorkOrder" 
                        ImageUrl="~/Images/print.png" Value="Print" OnLoad="GetItemURL" Target="_blank" PostBack="false"></telerik:RadToolBarButton> 
                </Items> 
            </telerik:RadToolBar> 
 

And here is the OnLoad event handler that sets the Navigate URL -- the button with the problem is the last button "Print".
    Protected Sub GetItemURL(ByVal sender As Object, ByVal e As System.EventArgs)  
        Dim item As Telerik.Web.UI.RadToolBarButton  
        If sender.GetType Is GetType(Telerik.Web.UI.RadToolBarButton) Then 
            item = DirectCast(sender, Telerik.Web.UI.RadToolBarButton)  
            Select Case item.Value  
                Case "AddNotes" 
                    item.NavigateUrl = "NoteEditor.aspx?TID=" & TicketID & "&MD=E" 
                Case "CloseTicket" 
                    item.NavigateUrl = "CloseWorkOrder.aspx?TID=" & TicketID  
                Case "AssignTicket" 
                    item.NavigateUrl = "NoteEditor.aspx?TID=" & TicketID & "&MD=A" 
                Case "MoveTicket" 
                    item.NavigateUrl = "NoteEditor.aspx?TID=" & TicketID & "&MD=M" 
                Case "EditDetails" 
                    item.NavigateUrl = "EditTicketDetails.aspx?TID=" & TicketID  
                Case "AssignGoal" 
                    item.NavigateUrl = "UpdateAccreditationGoal.aspx?TID=" & TicketID  
                Case "ReopenTicket" 
                    item.NavigateUrl = "ReopenTicket.aspx?TID=" & TicketID  
                Case "Print" 
                    item.NavigateUrl = "PrintTicketView.aspx?TID=" & TicketID  
                    item.Target = "_blank" 
            End Select 
            item.PostBack = False 
        End If 
    End Sub 
 

When I click on the print button, the URL is opened in a new window plus the parent window. Am I doing something wrong here?
Chris
Top achievements
Rank 1
 answered on 13 Nov 2009
3 answers
335 views

Hello,

        I want hide/unhide radgrid column depends on certain conditions.

       I have used Followinf Code provided by you on link
       http://demos.telerik.com/aspnet-ajax/grid/examples/client/clientsideapi/defaultcs.aspx

       function HideColumn(index)
                    {
                     var columnCount = RadGrid1.get_masterTableView().get_columns().length - 1;
                     if(index < 0 || index > columnCount)
                     {
                     alert("Invalid index! The valid range is: " + 0 + "-" + columnCount);
                     }
                     else
                     {
                         RadGrid1.get_masterTableView().hideColumn(index);
                        }
                    }

                    function ShowColumn(index)
                    {
                     var columnCount = RadGrid1.get_masterTableView().get_columns().length - 1;
                     if(index < 0 || index > columnCount)
                     {
                     alert("Invalid index! The valid range is: " + 0 + "-" + columnCount);
                     }
                     else
                     {
                         RadGrid1.get_masterTableView().showColumn(index);
                        }
                    }

        I have also set  AllowColumnHide="True" property.

         This code works well only when I provide dedicated button to call this methods.But when I call this Methods in between execution of business logic, I get follwoing problems

      1. showColumn(columnindex) itself hides the column
      2. once column is not visibile, it will not become visible even after calling "showColumn" Method.
      3. showColumn(columnindex) takes significant time to execute

Am I missing any property or any thing....

any help will be highly appreciated...
 
thanks in advance,

Ajay



Tsvetoslav
Telerik team
 answered on 13 Nov 2009
Narrow your results
Selected tags
Tags
+? more
Top users last month
Tien
Top achievements
Rank 1
Iron
Krasimir
Top achievements
Rank 3
Bronze
Iron
Iron
Cedar
Top achievements
Rank 1
Iron
Emil
Top achievements
Rank 1
Iron
Kyle Watson
Top achievements
Rank 1
Iron
Want to show your ninja superpower to fellow developers?
Top users last month
Tien
Top achievements
Rank 1
Iron
Krasimir
Top achievements
Rank 3
Bronze
Iron
Iron
Cedar
Top achievements
Rank 1
Iron
Emil
Top achievements
Rank 1
Iron
Kyle Watson
Top achievements
Rank 1
Iron
Want to show your ninja superpower to fellow developers?
Want to show your ninja superpower to fellow developers?