Telerik Forums
UI for ASP.NET AJAX Forum
1 answer
140 views
Hi, I want to apply filter on item template contains ternary how can do this.

 <telerik:GridTemplateColumn UniqueName="IsAverage"  HeaderText="Average/Sum" ItemStyle-HorizontalAlign="Left" HeaderStyle-HorizontalAlign="Left"  AllowFiltering="false" >                                                                                                                               
       <ItemTemplate>  
      <asp:Label Id="active" runat="server" Text='<%# Convert.ToBoolean(Eval("IsAverage")) == true ? "Average" : "Sum" %>'></asp:Label>                                                     </ItemTemplate>                                                                  
            <HeaderStyle HorizontalAlign="Left"></HeaderStyle>
       <ItemStyle HorizontalAlign="Left"></ItemStyle>
  </telerik:GridTemplateColumn>

please provide example or solution with source code.
Radoslav
Telerik team
 answered on 20 Nov 2014
3 answers
150 views
Hi, noob here so apologies in advance for any misconceptions but I downloaded the telerik demo and samples materials to a Win 8 with Visual Studio 2013 Professional installed in November 2014.  I've read/worked through the first half of the "UI for ASP.Net Ajax" pdf step by step tutorial as well as referenced/tried my hand at opening the CS solutions provided.  However, I'm not getting the sense this is the most productive strategy.  Yes, the pdf provides orientation but much of the specifics are -- I presume -- out of date for my setup.  Similarly the example solutions could imho use a "readme" page in the main directory detailing how to use them (including their age, the updates VS will require, how their file structure relates to the pdf etc).

My first question then is whether a better learning strategy or materials can be suggested.  (Fwiw I'd be willing to pay someone a moderate fee to be an answer resource that can speed my learning curve.) 

Secondly I have some database experience and wasted too much time researching MVC with its requisite EF/ORM "kludge" -- instead I want to normalize and tune a database then write stored procedures to connect with webform components (please advise of security or performance issues possibly resulting as appropriate).

Thanks in advance   
Marin Bratanov
Telerik team
 answered on 20 Nov 2014
1 answer
104 views
Hi All,

i am using Chart in one of my page. what i am trying to bind grid data in chart. Below is the example of data i am trying to bind. 

Carrier_Name               ActualBalance              30Days                  31-60Days                 61-90Days           90+ Days
----------------------------------------------------------------------------------------------------------------------------------------------------------------------------
Career1                              18644.00                  5370.00                   1263.00                      444.00                 11567.00                                                             Career2                              18185.00                  14019.00                 1331.00                      278.00                  2557.00                                                                     Career3                              5956.00                    5813.00                    0.000.00                    143.00                                                                                                   Career4                              4567.00                    0.00                          176.00                       0.00                     4391.00                                                                 Career5                              2418.00                    602.00                      0.00                           0.00                      1816.00


Now in my chart i want to bind all Actual Balance row in first Series, all 30Days row in second series , all 31-60Days row in third series and so on.

I have attached .jpg file for the output i am looking for. Please if anyone can help Thanks. 

 
Danail Vasilev
Telerik team
 answered on 20 Nov 2014
1 answer
104 views
Hi,

I have four static databound columns in radgrid like  Column1,column2, Column3 and Column4 with binding datatable its working fine  like sorting,paging. etc.
if i'm going to add additional one databound or numberic bound  column thats "Column5" through programatically  in pageinit event means its not working . same column adding more than once on each postback. Column5 ,Column6 without header..

Can you give sample project with this scenario?
Viktor Tachev
Telerik team
 answered on 20 Nov 2014
9 answers
678 views
Hi Experts

Is there any way to set/override the RadGrid Header Color while using the default skin.
I tried all possible ways and couldnt make it happen.

Thank you,
Deva
Fawad
Top achievements
Rank 1
 answered on 20 Nov 2014
13 answers
425 views
Hi ,

With the latest updates of RadAsyncUpload control, it asks for login credentials when a file is selected from browse window. We are using it in SharePoint Site.

This was working previously with earlier version and seems to be broken in the version 2010.2.713.20. When a sip file is selected from the browse window, the control keeps loading and does not complete the loading. 

Sometimes if the page is accessed over domain from another machine, it starts working but thats just sometimes. Its not at all working on same machine.

Its defined this way : 

<telerik:RadAsyncUpload ID="importPackage" runat="server" ControlObjectsVisibility="None" MaxFileInputsCount="1" EnableViewState="true" AllowedFileExtensions="zip" onkeypress="javascript:return false;" Localization-Select="browse" Width="300px" InputSize="45" Skin="Outlook" OverwriteExistingFiles="true" InitialFileInputsCount="1">
</telerik:RadAsyncUpload>

Not sure whats the problem. Can someone help ?  This is quite urgent.

Thanks,
Nutan
Plamen
Telerik team
 answered on 20 Nov 2014
1 answer
95 views
Hi, we have a grid with a RadAsyncUpload in EditFormSettings. Is from approximately 2 weeks that RadAsyncUpload don't work fine.

<telerik:RadGrid ID="RadGrid1" runat="server"
    CellSpacing="0" Culture="it-IT" GridLines="None" DataKeyNames="ID Modulo"
    DataSourceID="SqlDataSource1" AutoGenerateColumns="false" Width="820px" AllowSorting="true"
    OnInsertCommand="RadGrid1_InsertCommand" OnItemCommand="RadGrid1_ItemCommand" OnUpdateCommand="RadGrid1_UpdateCommand"
    Skin="Forest" EnableEmbeddedSkins="False" OnItemDataBound="RadGrid1_ItemDataBound">
    <MasterTableView DataKeyNames="ID Modulo" DataSourceID="SqlDataSource1" CommandItemDisplay="TopAndBottom">
        <ItemTemplate>
            <table style="width:800px;">
                <tr>
                    <td style="width: 80px;text-align:left;"><telerik:RadBinaryImage ID="RadBinaryImage1" runat="server" Width="64px" Height="64px" ResizeMode="Fit" DataValue='<%# Eval("Immagine") %>' /></td>
                    <td style="width: 100px;">
                        <div class="fModuli"><%#Eval("tProgressivo")%></div>
                        <div class="fModuli"><%#Eval("tTipo")%></div>
                    </td>
                    <td style="width: 400px;">
                        <b>Descrizione:</b> <%#Eval("tModulo")%><br />
                        <b>Data:</b> <%#Eval("tStamp")%>                                   
                    </td>
                    <td>
                        <table style="width:100%">
                            <tr>
                                <td style="text-align:left;"><asp:LinkButton ID="lnkEdit" runat="server" Text="Modifica" CommandName="Edit"></asp:LinkButton></td>
                            </tr>
                            <tr>
                                <td style="text-align:left;"><asp:LinkButton ID="lnkDelete" runat="server" Text="Elimina" CommandName="Delete" OnClientClick="return confirm('Sei sicuro di volerlo eliminare?')"></asp:LinkButton><asp:LinkButton ID="lnlDomRisp" runat="server" Text="Domande" CommandName="DomRis"></asp:LinkButton></td>
                            </tr>
                        </table>                               
                    </td>
                </tr>
            </table>
        </ItemTemplate>
        <Columns>
            <telerik:GridTemplateColumn>
                <HeaderStyle Width="130px" />
            </telerik:GridTemplateColumn>
            <telerik:GridBoundColumn HeaderText="Progressivo" DataField="Progressivo" UniqueName="Progressivo">
                <HeaderStyle Width="490px" />
            </telerik:GridBoundColumn>
            <telerik:GridTemplateColumn>
                <HeaderStyle Width="200px" />
            </telerik:GridTemplateColumn>
        </Columns>
        <EditFormSettings EditFormType="Template">
            <FormTemplate>
                <div style="margin-left:15px;">
                    <asp:Panel ID="pnlInsert" runat="server">
                        <div style="height:10px"></div>
                        <table style="width:800px">
                            <tr>
                                <td style="width:200px">Tipo Modulo <asp:DropDownList ID="DDLTipoModulo" runat="server" AutoPostBack="true" OnSelectedIndexChanged="DDLTipoModulo_SelectedIndexChanged" DataTextField="Descrizione" DataValueField="ID Tipo Modulo"></asp:DropDownList></td>
                            </tr>
                        </table>
                    </asp:Panel>   
                    <div style="height:10px"></div>
                    <table style="width:800px;">
                        <tr>
                            <td style="width:400px; vertical-align:top;">Descrizione:<br /><asp:TextBox ID="txtDescrizione" runat="server" Text='<%#Bind("tModulo")%>' MaxLength="255" Width="350px"></asp:TextBox></td>
                            <td style="vertical-align:top;"><asp:Panel ID="pnlArticulate" runat="server">Articulate: <a href="../public/moduli/<%=Hash%>/<%#Eval("Articulate")%>" target="_blank"><asp:Literal ID="lArticulate" runat="server" Text='<%#Eval("Articulate")%>'></asp:Literal></a><telerik:RadAsyncUpload ID="rupArticulate" runat="server" AllowedFileExtensions="zip" MaxFileSize="1010485760" MaxFileInputsCount="1" Skin="Forest" EnableEmbeddedSkins="False" Localization-Select="Seleziona" Localization-Cancel="Cancella" Localization-Remove="Rimuovi"></telerik:RadAsyncUpload></asp:Panel><asp:Panel ID="pnlDispensa" runat="server">Dispensa: <a href="../public/moduli/<%=Hash%>/<%#Eval("Dispensa")%>" target="_blank"><asp:Literal ID="lDispensa" runat="server" Text='<%#Eval("Dispensa")%>'></asp:Literal></a><telerik:RadAsyncUpload ID="rupDispensa" runat="server" AllowedFileExtensions="pdf" MaxFileSize="1010485760" MaxFileInputsCount="1" Skin="Forest" EnableEmbeddedSkins="False" Localization-Select="Seleziona" Localization-Cancel="Cancella" Localization-Remove="Rimuovi"></telerik:RadAsyncUpload></asp:Panel></td>
                        </tr>
                    </table>
                    <div style="height:10px"></div>
                    <table style="width:800px;">
                        <tr>
                            <td style="width:150px; vertical-align:top"><asp:Panel ID="pnlProgressivo" runat="server">Progressivo: <asp:TextBox ID="txtProgressivo" runat="server" Text='<%#Bind("Progressivo")%>' MaxLength="3" Width="50"></asp:TextBox><asp:RequiredFieldValidator ID="RFVProgressivo" runat="server" ErrorMessage="Inserire il progressivo" ControlToValidate="txtProgressivo" Text="*"></asp:RequiredFieldValidator><asp:RangeValidator ID="RVProgressivo" runat="server" ErrorMessage="Inserire un numero compreso tra 1 e 100" MaximumValue="100" MinimumValue="1" ControlToValidate="txtProgressivo" Text="*" Type="Integer"></asp:RangeValidator></asp:Panel><asp:Panel ID="pnlPercentualeCorrette" runat="server">% Corrette: <asp:TextBox ID="txtPerCorrette" runat="server" Text='<%#Bind("Percentuale_Corrette")%>' MaxLength="3" Width="50"></asp:TextBox><asp:RequiredFieldValidator ID="TFVPerCorrette" runat="server" ErrorMessage="Inserire la percentuale di domande corrette" ControlToValidate="txtPerCorrette" Text="*"></asp:RequiredFieldValidator><asp:RangeValidator ID="RVPerCorrette" runat="server" ErrorMessage="Inserire un numero compreso tra 1 e 100" MaximumValue="100" MinimumValue="1" ControlToValidate="txtPerCorrette" Text="*" Type="Integer"></asp:RangeValidator></asp:Panel></td>
                            <td style="width:150px; vertical-align:top"><asp:Panel ID="pnlDurata" runat="server">Durata: <asp:TextBox ID="txtDurata" runat="server" Text='<%#Bind("Durata")%>' MaxLength="10"  Width="50"></asp:TextBox><asp:RequiredFieldValidator ID="RFVDurata" runat="server" ErrorMessage="Inserire la durata" ControlToValidate="txtDurata" Text="*"></asp:RequiredFieldValidator><asp:RegularExpressionValidator ID="REVDurata" runat="server" Text="*" ErrorMessage="Durata non corretta" ControlToValidate="txtDurata" ValidationExpression="\d+"></asp:RegularExpressionValidator></asp:Panel></td>
                            <td style="vertical-align:top;"><asp:Panel ID="pnlnDomande" runat="server">Numero Domande: <asp:TextBox ID="txtNDomande" runat="server" Text='<%#Bind("Domande_Random")%>' MaxLength="3" Width="50"></asp:TextBox><asp:RequiredFieldValidator ID="RFVNDomande" runat="server" ErrorMessage="Inserire il numero di domande" ControlToValidate="txtNDomande" Text="*"></asp:RequiredFieldValidator><asp:RangeValidator ID="REVNDomande" runat="server" ErrorMessage="Inserire un numero compreso tra 1 e 100" MaximumValue="100" MinimumValue="1" ControlToValidate="txtNDomande" Text="*" Type="Integer"></asp:RangeValidator></asp:Panel></td>
                        </tr>
                    </table>
                </div>
                <div style="height:10px"></div>
                <div style="text-align:center;">
                    <asp:Button ID="btnUpdate" Text='<%# (Container is GridEditFormInsertItem) ? "Inserisci" : "Aggiorna" %>' runat="server" CommandName='<%# (Container is GridEditFormInsertItem) ? "PerformInsert" : "Update" %>' ></asp:Button> <asp:Button ID="btnCancel" Text="Annulla" runat="server" CausesValidation="False" CommandName="Cancel" ></asp:Button>
                </div>
                <div style="height:10px"></div>
                <asp:ValidationSummary ID="VS1" runat="server" ShowMessageBox="true" ShowSummary="false" />
            </FormTemplate>
        </EditFormSettings>
    </MasterTableView>
</telerik:RadGrid>


An error was raised

ReferenceError: xhtml is not defined
debugger eval code
Line 1

in attached the error debug.

How is possible solve the problem.
Peter Filipov
Telerik team
 answered on 20 Nov 2014
2 answers
161 views
Hi,

I used this sample http://demos.telerik.com/aspnet-ajax/editor/examples/customdialogs/defaultcs.aspx to get a Custom Dialog for the Editor. On that Dialog page I added a RadButton. This RadButton has a OnClientClicked Event with a Javascript function (Dialog return). The Problem is that this function gets fired on PageLoad (Dialog\RadWindow). If i use a normal ASP Button with "OnClientClick" all works fine. How is it possible to have the JavaScript function fired only on the Click event with a RadButton.


<%@ Page Language="C#" AutoEventWireup="true" CodeBehind="Dialog.aspx.cs" Inherits="TelerikSample.Dialog" %>

<!DOCTYPE html>

<html xmlns="http://www.w3.org/1999/xhtml">
<head runat="server">
<title></title>
</head>
<body>
<form id="form1" runat="server">
<telerik:RadScriptManager ID="RadScriptManager1" runat="server">
<Scripts>
<asp:ScriptReference Assembly="Telerik.Web.UI" Name="Telerik.Web.UI.Common.Core.js" />
<asp:ScriptReference Assembly="Telerik.Web.UI" Name="Telerik.Web.UI.Common.jQuery.js" />
<asp:ScriptReference Assembly="Telerik.Web.UI" Name="Telerik.Web.UI.Common.jQueryInclude.js" />
</Scripts>
</telerik:RadScriptManager>
<div>
<telerik:RadButton ID="RadButton1" runat="server" Text="RadButton" OnClientClicked="insertLink('IdOfList')"></telerik:RadButton>
<%--<asp:Button ID="Button2" runat="server" Text="ASPButton" OnClientClick="insertLink('IdOfList')" ></asp:Button>--%>
</div>
</form>
</body>
</html>


<script type="text/javascript">

function getRadWindow() {
if (window.radWindow) {
return window.radWindow;
}
if (window.frameElement && window.frameElement.radWindow) {
return window.frameElement.radWindow;
}
return null;
}

function insertLink(Id) //fires when the Insert Link button is clicked
{
getRadWindow().close(Id); //use the close function of the getRadWindow to close the dialog and pass the arguments from the dialog to the callback function on the main page.
}
</script>


Thanks,
Hermann
Hermann
Top achievements
Rank 1
 answered on 20 Nov 2014
0 answers
87 views
I'm trying to export Kendogrid data to excel file.

The exported excel file has all the space removed between the words, which is an issue.

Below is the sample page where I tried to replicate the same.
http://dojo.telerik.com/EtUj/6


Please help if anyone has any solution or workaround.
Thanks
Tanmayee
Top achievements
Rank 1
 asked on 20 Nov 2014
3 answers
98 views
hi

which find control for example, DropDownTree or ....
, in RadListView1_ItemEditing



i try below code,but give error.







  protected void RadListView1_ItemEditing(object sender, RadListViewCommandEventArgs e)

    {

RadListViewEditableItem editedItem = (RadListViewEditableItem)e.ListViewItem;



 RadTextBox txtSubject =(RadTextBox)editedItem.FindControl("txtSubject");



txtSubject .Text="hi";



}

please help me.

thanks

Pavlina
Telerik team
 answered on 19 Nov 2014
Narrow your results
Selected tags
Tags
+? more
Top users last month
Edmond
Top achievements
Rank 1
Iron
fabrizio
Top achievements
Rank 2
Iron
Veteran
RobMarz
Top achievements
Rank 2
Iron
Fakhrul
Top achievements
Rank 1
Iron
Tejas
Top achievements
Rank 2
Iron
Iron
Iron
Want to show your ninja superpower to fellow developers?
Top users last month
Edmond
Top achievements
Rank 1
Iron
fabrizio
Top achievements
Rank 2
Iron
Veteran
RobMarz
Top achievements
Rank 2
Iron
Fakhrul
Top achievements
Rank 1
Iron
Tejas
Top achievements
Rank 2
Iron
Iron
Iron
Want to show your ninja superpower to fellow developers?
Want to show your ninja superpower to fellow developers?