Telerik Forums
UI for ASP.NET AJAX Forum
1 answer
204 views

Hi All,

Requirement :

Allow only Number with decimal and in Mobile view,We should show only numeric keypad and not normal keypad

Issue:

I have RadTextbox which as inputtype as number(Number keypad is showing in Mobile View).When i tried to enter the decimal and press next button.It is not allowing to postback.So i tried with RadNumericTextBox,It allows to enter the decimal and postback.But in Mobile view, number keypad is not showing.We need to show number keypad in mobile and we need to allow decimal point for postback.Can anyone help on this please.Since this is really urgent requirement need a answer for this please.

Please help us 

 

Thanks

S A Saikrishnan

 

Attila Antal
Telerik team
 answered on 20 Apr 2020
3 answers
536 views
Any way to provide the functionality to upload an entire folder/directory?
Peter Milchev
Telerik team
 answered on 20 Apr 2020
25 answers
857 views
I have the following markup in my code which is a RadGrid inside an UpdatePanel inside a div on a user control.  Whenever I add a new row to the grid by clicking the 'Add Athlete' command bar button, it puts the grid into edit mode and sets focus to the first editor control perfectly.  The grid is located near the bottom of my page.  When I click 'Add Athlete' or edit an existing row, a post back is done as expected but the page's scrolled to position is lost; it always loads the page at 0,0 (top).  I have tried several approaches with no luck:

1) Javascript to save the x/y scrolled positions into a hidden field and scroll to those positions on load
2) "Parent.Page.MaintainScrollPositionOnPostBack = true" in my page_load event
3) <Scrolling AllowScroll="True" UseStaticHeaders="True" SaveScrollPosition="true" /> in the grid's definition
4) Setting my DNN module definition to 'Support partial rending' on and off          
5) Setting up a new project with a standard (non-master) page and using the following page declaration:
          <%@ Page Language="C#" AutoEventWireup="true" CodeBehind="WebForm1.aspx.cs" Inherits="Tester.WebForm1" MaintainScrollPositionOnPostBack="true" %>

Nothing works.  This is all hosted inside a custom user control which is a View module for DotNetNuke 6.

Any ideas?

My update panel and grid's definition:

<div>
    <asp:UpdatePanel runat="server" ChildrenAsTriggers="true" ID="upnlAthleteList">
        <ContentTemplate>
            <telerik:RadGrid ID="grdAthletes" runat="server" AllowAutomaticDeletes="True" AllowSorting="True"
                PageSize="12" AutoGenerateColumns="False" OnNeedDataSource="grdAthletes_NeedDataSource"
                OnItemCommand="grdAthletes_ItemCommand" OnPreRender="grdAthletes_PreRender" OnUpdateCommand="grdAthletes_UpdateCommand"
                Width="758px" OnDeleteCommand="grdAthletes_DeleteCommand" OnEditCommand="grdAthletes_EditCommand"
                OnItemDataBound="grdAthletes_ItemDataBound" ShowStatusBar="True" AllowAutomaticInserts="True"
                AllowAutomaticUpdates="True" OnItemCreated="grdAthletes_ItemCreated" Skin="Metro"
                BorderStyle="None" CellSpacing="0" GridLines="None" ForeColor="White" BackColor="Transparent"
                ShowFooter="True">
                <ValidationSettings ValidationGroup="AthletesGrid" />
                <ClientSettings AllowKeyboardNavigation="True">
                    <Selecting AllowRowSelect="True" />
                    <KeyboardNavigationSettings AllowSubmitOnEnter="True" AllowActiveRowCycle="True" />
                    <Scrolling AllowScroll="True" UseStaticHeaders="True" SaveScrollPosition="true" />
                    <ClientEvents OnKeyPress="OnKeyPress" OnRowSelected="RowSelected" OnRowClick="RowClick"
                        OnRowDblClick="RowDblClick" OnGridCreated="GridCreated" OnCommand="GridCommand" />
                    <Resizing ShowRowIndicatorColumn="False" />
                </ClientSettings>
                <AlternatingItemStyle BackColor="LightGray" BorderStyle="None" ForeColor="Black" />
                <MasterTableView NoMasterRecordsText="No athletes to display." EditMode="InPlace"
                    CommandItemDisplay="Bottom" BorderStyle="None" BackColor="Transparent" ShowFooter="False">
                    <HeaderStyle BorderStyle="None" Font-Bold="True" Font-Size="Medium" ForeColor="White"
                        Height="48px" HorizontalAlign="Left" VerticalAlign="Middle" Wrap="True" />
                    <CommandItemStyle CssClass="rgCommandRow" />
                    <FooterStyle BorderStyle="None" CssClass="grid-footer" />
                    <CommandItemTemplate>
                        <div>
                            <asp:LinkButton ID="btnAddNew" runat="server" CommandName="AddNewRow">
                                <img style="border:0px;vertical-align:middle;" alt="Add Athlete" src="Images/112_Plus_Green_32x42_72.png" /> Add Athlete</asp:LinkButton>  
                        </div>
                    </CommandItemTemplate>
                    <CommandItemSettings ExportToPdfText="Export to PDF" ShowRefreshButton="False" AddNewRecordText="Add Athlete">
                    </CommandItemSettings>
                    <RowIndicatorColumn FilterControlAltText="Filter RowIndicator column">
                        <HeaderStyle Width="20px"></HeaderStyle>
                    </RowIndicatorColumn>
                    <ExpandCollapseColumn FilterControlAltText="Filter ExpandColumn column">
                        <HeaderStyle Width="20px"></HeaderStyle>
                    </ExpandCollapseColumn>
                    <EditFormSettings EditFormType="Template">
                        <EditColumn FilterControlAltText="Filter EditCommandColumn column" CancelImageUrl="Cancel.gif"
                            InsertImageUrl="Update.gif" UpdateImageUrl="Update.gif" Visible="true" Display="true">
                        </EditColumn>
                    </EditFormSettings>
                    <ItemStyle BackColor="White" BorderStyle="None" ForeColor="Black" />
                    <AlternatingItemStyle BackColor="LightGray" BorderStyle="None" ForeColor="Black" />
                    <EditItemStyle BackColor="Gainsboro" BorderStyle="None" />
                    <PagerStyle PageSizeControlType="RadComboBox"></PagerStyle>
                    <Columns>
                        <telerik:GridBoundColumn ConvertEmptyStringToNull="False" DataField="RowCount" EmptyDataText="" FilterControlAltText="Filter RowCount column" HeaderText="" SortExpression="RowCount" UniqueName="RowCount" ReadOnly="true">
                            <HeaderStyle Wrap="False" HorizontalAlign="Left" Width="24px" CssClass="grid-header grid-header-first" />
                            <ItemStyle HorizontalAlign="Left" VerticalAlign="Middle" Width="24px" />
                        </telerik:GridBoundColumn>
                       <telerik:GridBoundColumn DataField="FirstName" HeaderText="First Name"
                            UniqueName="FirstName" ConvertEmptyStringToNull="False" SortExpression="FirstName"
                            EmptyDataText="" ColumnEditorID="txtGridEdit_FirstName" ColumnGroupName="AthleteName"
                            ShowSortIcon="False">
                            <ColumnValidationSettings EnableRequiredFieldValidation="True">
                                <RequiredFieldValidator ErrorMessage="<span class='red'>* Required</span>"></RequiredFieldValidator></ColumnValidationSettings>
                            <HeaderStyle Wrap="False" HorizontalAlign="Left" Width="90px" CssClass="grid-header" />
                            <ItemStyle HorizontalAlign="Left" Width="100%" VerticalAlign="Top" />
                        </telerik:GridBoundColumn>
                        <telerik:GridBoundColumn DataField="MiddleName" HeaderText="M. Name" UniqueName="MiddleName"
                            ConvertEmptyStringToNull="False" EmptyDataText="" SortExpression="MiddleName"
                            ColumnEditorID="txtGridEdit_MiddleName" ColumnGroupName="AthleteName" ShowSortIcon="False">
                            <HeaderStyle Wrap="False" HorizontalAlign="Left" Width="80px" CssClass="grid-header" />
                            <ItemStyle HorizontalAlign="Left" Width="100%" VerticalAlign="Top" />
                        </telerik:GridBoundColumn>
                        <telerik:GridBoundColumn DataField="LastName" HeaderText="Last Name" UniqueName="LastName"
                            ConvertEmptyStringToNull="False" SortExpression="LastName" EmptyDataText="" ColumnEditorID="txtGridEdit_LastName"
                            ColumnGroupName="AthleteName" ShowSortIcon="False">
                            <ColumnValidationSettings EnableRequiredFieldValidation="True">
                                <RequiredFieldValidator ErrorMessage="* Required"></RequiredFieldValidator></ColumnValidationSettings>
                            <HeaderStyle Wrap="False" HorizontalAlign="Left" Width="90px" CssClass="grid-header" />
                            <ItemStyle HorizontalAlign="Left" Width="100%" VerticalAlign="Top" />
                        </telerik:GridBoundColumn>
                        <telerik:GridTemplateColumn HeaderText="Gender" SortExpression="Gender" UniqueName="Gender"
                            DataField="Gender" FilterControlAltText="Filter Gender column" ColumnEditorID="cmbGridEdit_Gender"
                            ShowSortIcon="False">
                            <ItemTemplate>
                                <%# DataBinder.Eval(Container.DataItem, "Gender") %></ItemTemplate>
                            <EditItemTemplate>
                                <asp:DropDownList ID="ddlGender" runat="server">
                                    <Items>
                                        <asp:ListItem Text="Female" Value="Female" />
                                        <asp:ListItem Text="Male" Value="Male" Selected="True" />
                                    </Items>
                                </asp:DropDownList>
                            </EditItemTemplate>
                            <HeaderStyle Wrap="False" HorizontalAlign="Left" Width="80px" CssClass="grid-header" />
                            <ItemStyle HorizontalAlign="Left" Width="90%" VerticalAlign="Top" />
                        </telerik:GridTemplateColumn>
                        <telerik:GridDateTimeColumn ConvertEmptyStringToNull="False" DataField="DoB" FilterControlAltText="Filter DoB column"
                            HeaderText="Date of Birth" SortExpression="DoB" UniqueName="DoB" DataFormatString="{0:M/d/yy}"
                            DataType="System.DateTime" EmptyDataText="" ColumnEditorID="dtGridEdit_DoB" ShowFilterIcon="False"
                            EditDataFormatString="M/d/yy" MaxLength="8" ShowSortIcon="False">
                            <ColumnValidationSettings EnableRequiredFieldValidation="True">
                                <RequiredFieldValidator ErrorMessage="* Max age: 20" ID="valReqDoB"></RequiredFieldValidator>
                            </ColumnValidationSettings>
                            <HeaderStyle Wrap="False" HorizontalAlign="Left" Width="106px" CssClass="grid-header" />
                            <ItemStyle Width="100%" HorizontalAlign="Left" VerticalAlign="Top"></ItemStyle>
                        </telerik:GridDateTimeColumn>
                        <telerik:GridMaskedColumn ConvertEmptyStringToNull="False" DataField="ZipCode" DataFormatString="{0:#####}"
                            FilterControlAltText="Filter ZipCode column" HeaderText="Zip Code" Mask="#####"
                            SortExpression="ZipCode" UniqueName="ZipCode" EmptyDataText="" ShowSortIcon="False">
                            <ColumnValidationSettings EnableRequiredFieldValidation="True">
                                <RequiredFieldValidator ErrorMessage="* Required"></RequiredFieldValidator></ColumnValidationSettings>
                            <HeaderStyle Wrap="False" HorizontalAlign="Left" Width="80px" CssClass="grid-header" />
                            <ItemStyle Width="100%" HorizontalAlign="Left" VerticalAlign="Top"></ItemStyle>
                        </telerik:GridMaskedColumn>
                        <telerik:GridBoundColumn ConvertEmptyStringToNull="False" DataField="Email" FilterControlAltText="Filter Email column"
                            HeaderText="Email" SortExpression="Email" UniqueName="Email" EmptyDataText=""
                            ColumnEditorID="txtGridEdit_General_Large" ShowSortIcon="False">
                            <ColumnValidationSettings EnableRequiredFieldValidation="True">
                                <RequiredFieldValidator ErrorMessage="* Required" ID="valEmailColumnRequired" />
                            </ColumnValidationSettings>
                            <HeaderStyle Width="160px" Wrap="False" HorizontalAlign="Left" CssClass="grid-header" />
                            <ItemStyle HorizontalAlign="Left" Width="100%" VerticalAlign="Top" />
                        </telerik:GridBoundColumn>
                        <telerik:GridBoundColumn ConvertEmptyStringToNull="False" DataField="UniqueID" EmptyDataText=""
                            FilterControlAltText="Filter column column" HeaderText="Unique ID" SortExpression="UniqueID"
                            UniqueName="UniqueID" Visible="False">
                            <HeaderStyle CssClass="grid-header" />
                            <ItemStyle HorizontalAlign="Left" VerticalAlign="Top" />
                        </telerik:GridBoundColumn>
                        <telerik:GridButtonColumn ButtonType="ImageButton" CommandName="Edit" FilterControlAltText="Filter DeleteColumn column"
                            ImageUrl="Images/126_Edit_16x16_72.png" Text="" UniqueName="EditColumn" Resizable="false"
                            ConfirmDialogType="RadWindow">
                            <HeaderStyle Wrap="False" HorizontalAlign="Left" Width="24px" CssClass="grid-header">
                            </HeaderStyle>
                            <ItemStyle Width="100%" HorizontalAlign="Right" VerticalAlign="Top" />
                        </telerik:GridButtonColumn>
                        <telerik:GridButtonColumn ButtonType="ImageButton" CommandName="Delete" FilterControlAltText="Filter DeleteColumn column"
                            ImageUrl="Images/305_Close_16x16_72.png" Text="" UniqueName="DeleteColumn" Resizable="false"
                            ConfirmText="Remove this athelete?" ConfirmDialogType="RadWindow" ConfirmTitle="Remove"
                            ShowInEditForm="True">
                            <HeaderStyle Wrap="False" HorizontalAlign="Left" Width="24px" CssClass="grid-header grid-header-last">
                            </HeaderStyle>
                            <ItemStyle Width="100%" HorizontalAlign="Right" VerticalAlign="Top" />
                        </telerik:GridButtonColumn>
                    </Columns>
                </MasterTableView><EditItemStyle BackColor="Gainsboro" BorderStyle="None" />
                <FooterStyle BorderStyle="None" />
                <HeaderStyle BorderStyle="None" Height="48px" HorizontalAlign="Left" VerticalAlign="Middle" />
                <CommandItemStyle CssClass="rgCommandRow" />
                <ItemStyle BackColor="White" BorderStyle="None" ForeColor="Black" />
                <PagerStyle PageSizeControlType="RadComboBox"></PagerStyle>
                <SelectedItemStyle BorderStyle="None" />
                <FilterMenu EnableImageSprites="False">
                </FilterMenu>
                <HeaderContextMenu CssClass="GridContextMenu GridContextMenu_Default">
                </HeaderContextMenu>
            </telerik:RadGrid><br />
            <asp:Panel id="pnlMaxAthletesNote" style="display:none;" runat="server">
                <asp:Label runat="server" ID="lblMaxAthletes" Text="The maximum number of athletes for this team is {0}" CssClass="red" />
            </asp:Panel>
            <telerik:GridTextBoxColumnEditor ID="txtGridEdit_FirstName" runat="server" TextBoxStyle-Width="98%" />
            <telerik:GridTextBoxColumnEditor ID="txtGridEdit_MiddleName" runat="server" TextBoxStyle-Width="98%" />
            <telerik:GridTextBoxColumnEditor ID="txtGridEdit_LastName" runat="server" TextBoxStyle-Width="98%" />
            <telerik:GridTextBoxColumnEditor ID="txtGridEdit_General_Large" runat="server" TextBoxStyle-Width="98%" />
            <telerik:GridDateTimeColumnEditor runat="server" ID="dtGridEdit_DoB" TextBoxStyle-Width="98%" />
            <telerik:GridDropDownListColumnEditor ID="cmbGridEdit_Gender" runat="server" DropDownStyle-Width="98%" />
        </ContentTemplate>
    </asp:UpdatePanel>
</div>

olivia
Top achievements
Rank 1
 answered on 17 Apr 2020
2 answers
200 views

Hii all,

 

i have radGrid inside RadWindow, when radwindow close i want to rebind and clear filter data radGrid on client side,

i use this code but not work.

function RebindGrid() {
        var masterTable = $find("<%= RgDataEmployee.ClientID %>").get_masterTableView();
        masterTable.get_filterExpressions().clear();
        masterTable.rebind();
}
Sanji
Top achievements
Rank 1
 answered on 17 Apr 2020
2 answers
481 views

Hello,

I have a Problem with Spreadsheet.

I add the Assembly Telerik.Web.Spreadsheet, Version=2018.2.710.40 into my asp.net Project

But when i run the website, the following error is showing up:

Could not load file or assembly 'Telerik.Windows.Documents.Spreadsheet, Version=2018.3.516.40, Culture=neutral, PublicKeyToken=xxxxxxxxxxxxxxxx' or one of its dependencies. The located assembly's manifest definition does not match the assembly reference. (Exception from HRESULT: 0x80131040)

 

Not sure why it is looking for version 2018.3.516.40 when the assembly references version id 2018.2.710.40 and it is also set to Copy Local = True.

What can i do?

 

Manuel
Top achievements
Rank 1
 answered on 17 Apr 2020
1 answer
587 views

I want to save appointment data that selected by user in database. I haven't found any solution on telerik site. 

Please help me on this issue. 

Peter Milchev
Telerik team
 answered on 16 Apr 2020
1 answer
264 views

I have a rad list box as follows:

<telerik:RadListBox runat="server" ID="RadListBox1" Height="375px" Width="750px" DataSourceID="SqlDataSource2"
    AllowReorder="true" AutoPostBackOnReorder="true" EnableDragAndDrop="true" ButtonSettings-ShowReorder="true"
    AllowAutomaticUpdates="true" DataKeyField="SectionSort_ID" DataTextField="Header_Title" DataValueField="Header_Image" DataSortField="SectionSort_SortOrder"SelectionMode="Multiple">
    <ItemTemplate>
        <telerik:RadNumericTextBox RenderMode="Lightweight" runat="server" ID="ItemNo" Width="60px" MinValue="1"
            MaxValue="50" ShowSpinButtons="true" Value='1' NumberFormat-DecimalDigits="0" Skin="Bootstrap">
        </telerik:RadNumericTextBox>
        <img class="product-image" src='<%# DataBinder.Eval(Container, "Value")%>'>
        <span class="product-title"><%# DataBinder.Eval(Container, "Text")%></span>
    </ItemTemplate>
</telerik:RadListBox>

 

I want to set the RadNumericTextBox value in the databound event

I have tried the following:

Protected Sub RadListBox1_ItemDataBound(sender As Object, e As RadListBoxItemEventArgs) Handles RadListBox1.ItemDataBound
    If TypeOf e.Item Is RadListBoxItem Then
        Dim item = CType(e.Item, RadListBoxItem)
        Dim ItemNo As RadNumericTextBox = CType(item.FindControl("ItemNo"), RadNumericTextBox)
        ItemNo.Value = e.Item.DataItem("SectionSort_ItemNo")
    End If
End Sub

 

But I get this:

 

Specified cast is not valid.

based on this line

ItemNo.Value = e.Item.DataItem("SectionSort_ItemNo")

So basically how do i set the value of the text box in the databound event?

 

 

 

 

 

 

 

 

 

 

Jon
Top achievements
Rank 2
Veteran
 answered on 16 Apr 2020
5 answers
498 views

Hi All,

I have a radEditor that is being used as email template creator for email blasting. User can select image they want to put on their template.

Now the issue is email received does not display any images added to the template.

I have already added <telerik:RadEditor ContentFilters="MakeUrlsAbsolute,FixEnclosingP" ...

but to no avail. Still cant show images.

Thanks in advance,

Ryan

Rumen
Telerik team
 answered on 15 Apr 2020
4 answers
175 views

     Here is my code.  I am getting a yellow icon on the upload control and it is not uploading.

HTML

telerik:RadCloudUpload ID="CloudUpload" runat="server" MultipleFileSelection="Automatic" HttpHandlerUrl="~/UploadToCustomFolderHandler.ashx"  
OnClientFileSelected="onClientFileSelected" OnFileUploaded="CloudUpload_FileUploaded" AllowedFileExtensions="xlsx,xls,doc,pdf,docx,png,tiff" ProviderType="Azure">
</telerik:RadCloudUpload> 

JS

function onClientFileSelected(sender, args) {    
        var UBID =  document.getElementById('<%= hfUBID %>').value
        sender._module._handlerUrl = "/UploadToCustomFolderHandler.ashx?UBID=" + UBID;
}

It never gets to the HttpHandlerUrl as I have a break point set if it does. 

Here is the code in the handler that is not getting data.

string ubid = HttpContext.Current.Request["UBID"];

Peter Milchev
Telerik team
 answered on 15 Apr 2020
3 answers
235 views
Hello,

Is it possible to do Image Processing using RAD controls?

Jayanthi
Vessy
Telerik team
 answered on 15 Apr 2020
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?