Telerik Forums
UI for ASP.NET AJAX Forum
2 answers
261 views

Hi,

Whenever my page posts back all data in the spreadsheet is lost - is this expected behaviour?

I haven't tried this by loading a file but assume it will work the same way as I am doing it ie. populating data manually into cells.

Ivan Danchev
Telerik team
 answered on 22 Nov 2016
0 answers
112 views
We have implemented Radcombobox for multiselect drop-down. I really need help to implement cascading drop-down on Radcombobox multiselect through client side functionality. Any help or suggestion or reference would be really helpful??
Bala
Top achievements
Rank 1
 asked on 22 Nov 2016
2 answers
1.0K+ views

 I have added my RadDateTimePicker to a asp:Repeater. on first load the data binding will be empty and this cause the error Value of '1/1/0001 12:00:00 AM' is not valid for 'SelectedDate'. 'SelectedDate' should be between 'MinDate' and 'MaxDate'

i would like to know how to i set the selecteddate to empty string or null value.

i have tried to set the selecteddate to current datetime, but it screw up the timepicker format and the interval setting

 

i tried doing  DateTime.Now.ToString("dd/MM/yyy HH:mm") and got the error

System.FormatException: String was not recognized as a valid DateTime

 

my markup

01.<asp:Repeater ID="rptReplyDate" runat="server" OnItemDataBound="rptReplyDate_ItemDataBound">
02.    <HeaderTemplate>
03.        <table cellpadding="0px" cellspacing="0px" class="mainTable">
04.    </HeaderTemplate>
05.    <FooterTemplate>
06.        </table>
07.    </FooterTemplate>
08.    <ItemTemplate>
09.        <tr>
10.            <td style="padding: 1em 1em;">
11.                <table cellpadding="0px" cellspacing="0px" class="repeaterTable">
12.                    <tr>
13.                        <td>
14.                            <telerik:RadDateTimePicker ID="txtReplayDate" runat="server" SelectedDate='<%# Convert.ToDateTime( DataBinder.Eval(Container.DataItem, "completetion")) %>'>
15.                                <TimeView TimeFormat="HH:mm:ss" runat="server">
16.                                </TimeView>
17.                                <DateInput DisplayDateFormat="dd/MM/yyyy HH:mm" runat="server">
18.                                </DateInput>
19.                            </telerik:RadDateTimePicker>
20.                        </td>
21.                    </tr>
22.                     
23.                </table>
24.            </td>
25.        </tr>
26.    </ItemTemplate>
27.</asp:Repeater>

my code

01.protected void Page_Load(object sender, EventArgs e)
02.        {
03.            if (!Page.IsPostBack)
04.            {
05.                List<ReplayDate> col = new List<ReplayDate>();
06.                ReplayDate newData = new ReplayDate();
07.                newData.completetion = DateTime.Now.ToString();
08.                newData.id = 0;
09.                col.Add(newData);
10.                rptReplyDate.DataSource = col;
11.                rptReplyDate.DataBind();
12. 
13.             }
14.}
15.    public class ReplayDate
16.    {
17.        public int id { get; set; }
18.        public string completetion { get; set; }
19.    }
Benjamin
Top achievements
Rank 1
 answered on 22 Nov 2016
0 answers
95 views

I'm trying to access the InnerText for a header on the website I am testing, but I'm not able to get the string.  It keeps telling me that there isn't a definition for InnerText. I previously used InnerText to get the text from a Span - is there another keyword or, rather, how would i go about doing this??

 

Thank you,

 

M

Maxwell
Top achievements
Rank 1
 asked on 21 Nov 2016
2 answers
119 views

Hi,

I had a page that uses radmenu and it works just fine with the metro theme. As soon as I add a RadSpreadsheet control to my form then the styling of the menu goes haywire (colour is different, text is black instead of white), remove the spreadsheet control and all is back to normal again. What could cause this?

Magdalena
Telerik team
 answered on 21 Nov 2016
5 answers
388 views
Hello,

    I have two application. In one application i am using rad control version of 2007 and in another application i am using rad control 2008. My problem is when i enter text in rad editor in 2008 version which contents single line space between paragraphs. and save it in the database with rad control version 2008 and when i open the same text in radeditor version of 2007 it gives me three line space between paragraph. Can you help in this issue which is very Urgently required.

Thanks & Regards,
R. Vikram Goud
Rumen
Telerik team
 answered on 21 Nov 2016
8 answers
354 views
Hi,

I'm having some issues with the number format of RadNumericTextBox. If I for example want the NumberFormat-PositivePattern to be "n tons" and set the value to 123 the control's text gets rendered by the server as "123 to123s".

If I go to the field and then switch the focus to another field the javascript side of the formatting corrects the text to "123 tons".

If I use "tons n" as the format, the server renders "to123s 123" and the javascript renders "to123s n".

Clearly the server and client code are interpreting my format differently. So the bottom line seems to be that the server switches all occurences of 'n' to the value while the javascript switches only the first occurence of 'n' to the value.

I actually think the server does the correct thing (at least compared to the javascript). I think that the n in tons should be escaped by me somehow, but I can't find any mentioning of that in the manuals. The only thing I find is this text:

"The characters other than n in a formatting pattern are literal symbols. If you use the dollar sign ("$") as a currency symbol, for example, currency values are formatted using that symbol regardless of the value of the Culture property."

Could you spread some light on this issue?

Regards,
Martin
Vasil
Telerik team
 answered on 21 Nov 2016
3 answers
1.0K+ views

I have read several posts about how to do this.  I have also reviewed the documentation but I still can't get it figured out.  I have a grid with a template column containing a link button:

<telerik:RadGrid
    ID="rg_ven_docs"
    runat="server"
    DataSourceID="sdc_rg_ven_docs"
    AutoGenerateColumns="False"
    AllowPaging="True"
    AllowSorting="True"
    AllowFilteringByColumn="True"
    ShowGroupPanel="True"
    Skin="Office2010Blue"
    ClientSettings-EnablePostBackOnRowClick="True"
    CellSpacing="-1"
    GridLines="Both"
    OnSelectedIndexChanged="rg_ven_docs_SelectedIndexChanged"
    OnPreRender="rg_ven_docs_PreRender"
    OnItemCommand="rg_ven_docs_ItemCommand"
    EnableViewState="true"
    PageSize="5">
    <ClientSettings
        AllowDragToGroup="True"
        AllowColumnsReorder="True"
        ReorderColumnsOnClient="True">
    </ClientSettings>
    <MasterTableView DataSourceID="sdc_rg_ven_docs" DataKeyNames="docIdPk" ShowHeadersWhenNoRecords="true" CommandItemDisplay="Top" CommandItemSettings-ShowAddNewRecordButton="false" CommandItemSettings-ShowRefreshButton="true" >
        <Columns>
            <telerik:GridButtonColumn Text="Select" CommandName="Select" ButtonType="LinkButton"></telerik:GridButtonColumn>
            <telerik:GridBoundColumn DataField="docIdPk" ReadOnly="True" HeaderText="docIdPk" SortExpression="docIdPk" UniqueName="docIdPk" DataType="System.Int32" FilterControlAltText="Filter docIdPk column"></telerik:GridBoundColumn>
            <telerik:GridBoundColumn DataField="venDocTitle" HeaderText="Title" SortExpression="venDocTitle" UniqueName="venDocTitle" FilterControlAltText="Filter venDocTitle column" HeaderStyle-HorizontalAlign="Center" ItemStyle-HorizontalAlign="Center" HeaderStyle-Font-Bold="true"></telerik:GridBoundColumn>                                               
            <telerik:GridBoundColumn DataField="docType" HeaderText="Document Type" SortExpression="docType" UniqueName="docType" FilterControlAltText="Filter docType column" HeaderStyle-HorizontalAlign="Center" ItemStyle-HorizontalAlign="Center" HeaderStyle-Font-Bold="true"></telerik:GridBoundColumn
            <telerik:GridBoundColumn DataField="contType" HeaderText="Contract Type" SortExpression="contType" UniqueName="contType" FilterControlAltText="Filter contType column" HeaderStyle-HorizontalAlign="Center" ItemStyle-HorizontalAlign="Center" HeaderStyle-Font-Bold="true"></telerik:GridBoundColumn>                       
            <telerik:GridBoundColumn DataField="org" HeaderText="Organization" SortExpression="org" UniqueName="org" FilterControlAltText="Filter org column" HeaderStyle-HorizontalAlign="Center" ItemStyle-HorizontalAlign="Center" HeaderStyle-Font-Bold="true"></telerik:GridBoundColumn>
            <telerik:GridBoundColumn DataField="dept" HeaderText="Department" SortExpression="dept" UniqueName="dept" FilterControlAltText="Filter dept column" HeaderStyle-HorizontalAlign="Center" ItemStyle-HorizontalAlign="Center" HeaderStyle-Font-Bold="true"></telerik:GridBoundColumn>
            <telerik:GridBoundColumn DataField="PriorContCd" HeaderText="Prior Contract Code" SortExpression="PriorContCd" UniqueName="PriorContCd" FilterControlAltText="Filter PriorContCd column" HeaderStyle-HorizontalAlign="Center" ItemStyle-HorizontalAlign="Center" HeaderStyle-Font-Bold="true"></telerik:GridBoundColumn>
            <telerik:GridBoundColumn DataField="stat" HeaderText="Status" SortExpression="stat" UniqueName="stat" FilterControlAltText="Filter stat column" HeaderStyle-HorizontalAlign="Center" ItemStyle-HorizontalAlign="Center" HeaderStyle-Font-Bold="true"></telerik:GridBoundColumn>
            <telerik:GridBoundColumn DataField="crntDocStatDtSet" ReadOnly="True" HeaderText="Status Date" SortExpression="crntDocStatDtSet" UniqueName="crntDocStatDtSet" DataType="System.DateTime" FilterControlAltText="Filter crntDocStatDtSet column" HeaderStyle-HorizontalAlign="Center" ItemStyle-HorizontalAlign="Center" HeaderStyle-Font-Bold="true"></telerik:GridBoundColumn>
            <telerik:GridBoundColumn DataField="venIdFk" HeaderText="venIdFk" SortExpression="venIdFk" UniqueName="venIdFk" DataType="System.Int32" FilterControlAltText="Filter venIdFk column" ReadOnly="true"></telerik:GridBoundColumn>                                                                               
            <telerik:GridTemplateColumn DataField="venDocPath" HeaderText="Download" SortExpression="venDocPath" UniqueName="venDocPath" FilterControlAltText="Filter venDocPath column">
                <ItemTemplate>                         
                    <asp:LinkButton ID="lnkDownload" Text="Download" CommandArgument='<%# Eval("venDocPath") %>' runat="server" OnClick="lnkDownload_Click"></asp:LinkButton>
                </ItemTemplate>
            </telerik:GridTemplateColumn>
        </Columns>
    </MasterTableView>
</telerik:RadGrid>

Here is the OnClick event of the link button:

protected void lnkDownload_Click(object sender, EventArgs e)
        {
            string filePath = (sender as LinkButton).CommandArgument;
            Response.ContentType = ContentType;
            Response.AppendHeader("Content-Disposition", "attachment; filename=" + Path.GetFileName(filePath));
            Response.WriteFile(filePath);
            Response.End();
        }

 

I am still unable to get the file to download.

I have tried the following as well, but I still couldn't get the file to download - Download File From Grid Column

I also reviewed this demo - Column Types in Grid

Any help would be greatly appreciated.

Thanks,

J

Eyup
Telerik team
 answered on 21 Nov 2016
1 answer
446 views

Hi,

I have a form where I have telerik date picker and a asp button. On page load everything is working as expected, However, once the save button is clicked, page renders again and I no longer see the calendar when i hit on calendar icon in rad date picker.

Viktor Tachev
Telerik team
 answered on 21 Nov 2016
1 answer
134 views

Hello I have an issue with RadWindow.

On my detail (nested) grid I have a GridButtonColumn with properties set:

CommandName="Delete" Text="Delete" UniqueName="DeleteColumn" ButtonType="ImageButton" ImageUrl="~\images\icons\remove-icon-small.png"  ConfirmText="Are you sure you want to delete?" ConfirmDialogType="RadWindow"

 

Everything is working fine untill I expand more than one parent grid item and try to delete nested grid item.

RadWindows is goin to left-top corner of a browser and confirmation doesn't work - deleting items is working but confirmation windows doesn't appear.

Looking forward to you reply.

Marin Bratanov
Telerik team
 answered on 21 Nov 2016
Narrow your results
Selected tags
Tags
+? more
Top users last month
Jay
Top achievements
Rank 3
Bronze
Iron
Iron
yw
Top achievements
Rank 2
Iron
Iron
Stefan
Top achievements
Rank 2
Iron
Iron
Iron
Kao Hung
Top achievements
Rank 1
Iron
Bohdan
Top achievements
Rank 2
Iron
Iron
Iron
Want to show your ninja superpower to fellow developers?
Top users last month
Jay
Top achievements
Rank 3
Bronze
Iron
Iron
yw
Top achievements
Rank 2
Iron
Iron
Stefan
Top achievements
Rank 2
Iron
Iron
Iron
Kao Hung
Top achievements
Rank 1
Iron
Bohdan
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?