Jquery Calendar Inside a radgrid

5 posts, 0 answers
  1. Vvamc
    Vvamc avatar
    22 posts
    Member since:
    Jan 2014

    Posted 27 Jan 2014 Link to this post

    Hi ,

    I wanted to have a column with J-query calendar and i am not able to achieve this using rad grid .But  the normal grid i am able to assign it with the class name. Can you help me out.

    Thanks 
    Vk
  2. Shinu
    Shinu avatar
    17764 posts
    Member since:
    Mar 2007

    Posted 28 Jan 2014 in reply to Vvamc Link to this post

    Hi,

    Please try the following code snippet to show JQuery DatePicker in RadGrid.

    ASPX:
    <telerik:RadGrid ID="RadGrid1" runat="server" AutoGenerateColumns="false"                                        DataSourceID="SqlDataSource1">
        <MasterTableView>
            <Columns>
                <telerik:GridTemplateColumn>
                    <ItemTemplate>
                        <input type="text" id="datepicker" value='<%# Eval("OrderDate") %>'>
                    </ItemTemplate>
                </telerik:GridTemplateColumn>
            </Columns>
        </MasterTableView>
    </telerik:RadGrid>

    JavaScript:
    </script>
    </script>
        rel="Stylesheet" type="text/css" />
    <script type="text/javascript">
        $(function () {
            $("[id$=datepicker]").datepicker({
                showOn: 'button',
                buttonImageOnly: true,
            });
        });
    </script>

    Hope this will helps you.
    Thanks,
    Shinu.
  3. UI for ASP.NET Ajax is Ready for VS 2017
  4. Vvamc
    Vvamc avatar
    22 posts
    Member since:
    Jan 2014

    Posted 28 Jan 2014 in reply to Shinu Link to this post

    Thanks a lot shinu.It works perfectly.
  5. Karu
    Karu avatar
    3 posts
    Member since:
    Feb 2012

    Posted 30 Jun 2014 Link to this post

     <telerik:GridTemplateColumn AllowFiltering="false" HeaderText="Date" UniqueName="R_Date" HeaderStyle-Font-Bold="true" HeaderStyle-Font-Size="Small">
                                    <ItemTemplate>
                                        <telerik:RadDatePicker ID="RadDatePicker1" runat="server" Width="100px" DatePopupButton-Visible="false"
                                            ShowPopupOnFocus="true" DbSelectedDate='<%# Bind("R_Date") %>'>
                                            <DateInput ID="DateInput1" runat="server" DateFormat="MM/dd/yyyy" onkeydown="keyDown(this, event)">
                                            </DateInput>
                                        </telerik:RadDatePicker>                                    
                                    </ItemTemplate>
                                </telerik:GridTemplateColumn> I am using Telerik Rad datepicker to showin the grid . thats working fine. But problem is - Export to PDF am not able to get the DatePicker value. 


  6. Eyup
    Admin
    Eyup avatar
    3005 posts

    Posted 03 Jul 2014 Link to this post

    Hello Karu,

    In addition to the suggestion in this post:
    http://www.telerik.com/forums/problem-with-export-to-excel-with-template-columns-data-not-displaying#864sWWuHPkCNUJgfy_Usag

    I am sending a sample RadGrid web site to demonstrate how you can achieve the requested functionality. Please run the attached application and let me know if it helps you.

    Regards,
    Eyup
    Telerik
     

    Check out the Telerik Platform - the only platform that combines a rich set of UI tools with powerful cloud services to develop web, hybrid and native mobile apps.

     
Back to Top
UI for ASP.NET Ajax is Ready for VS 2017