Telerik Forums
UI for ASP.NET AJAX Forum
1 answer
80 views
Hi,
I have a radgrid that need paging. The problem is that it can only display 1 page even if there are more than 1 page. Also on right side displaying "0 item in 1 page" is not correct.  Also I want to add feature that can go to specific page entered. The problem is in image "Pager_problem.jpg". The desired pager style is in image "PagerStyle.jpg". Thanks.    The code is:
<telerik:RadGrid ID="RadGrid1" runat="server" style="margin-left:5px"
    AllowPaging="True" AllowCustomPaging="True"
    AllowFilteringByColumn="True"  AllowSorting="True"                
    DataSourceID="SqlDataSource1" GridLines="None">
 
    <MasterTableView DataSourceID="SqlDataSource1" AutoGenerateColumns="False"
         PagerStyle-Position="TopAndBottom"
         PagerStyle-AlwaysVisible="true" PagerStyle-Mode="NextPrevAndNumeric" PageSize="10">
    <RowIndicatorColumn>
    <HeaderStyle Width="20px"></HeaderStyle>
    </RowIndicatorColumn>
         
    <ExpandCollapseColumn>
    <HeaderStyle Width="20px"></HeaderStyle>
    </ExpandCollapseColumn>
        <Columns>
            <telerik:GridBoundColumn DataField="OrderDate" DataType="System.DateTime"
                HeaderText="Order Date" SortExpression="OrderDate"
                CurrentFilterFunction="Contains" AutoPostBackOnFilter="true" UniqueName="OrderDate">
            </telerik:GridBoundColumn>
            <telerik:GridBoundColumn DataField="FirstName" HeaderText="First Name"
                SortExpression="FirstName" CurrentFilterFunction="Contains" AutoPostBackOnFilter="true" UniqueName="FirstName">
            </telerik:GridBoundColumn>
            <telerik:GridBoundColumn DataField="Email" HeaderText="Email"
                SortExpression="Email" CurrentFilterFunction="Contains" AutoPostBackOnFilter="true" UniqueName="Email">
            </telerik:GridBoundColumn>
            <telerik:GridBoundColumn DataField="GreetingCode" HeaderText="Greeting Code"
                SortExpression="GreetingCode" CurrentFilterFunction="Contains" AutoPostBackOnFilter="true" UniqueName="GreetingCode">
            </telerik:GridBoundColumn>
            <telerik:GridBoundColumn DataField="ChildFirstName" HeaderText="Child's FirstName"
                SortExpression="ChildFirstName" CurrentFilterFunction="Contains" AutoPostBackOnFilter="true" UniqueName="ChildFirstName">
            </telerik:GridBoundColumn>
            <telerik:GridBoundColumn DataField="ChildLastName" HeaderText="Child's LastName"
                SortExpression="ChildLastName" CurrentFilterFunction="Contains" AutoPostBackOnFilter="true" UniqueName="ChildLastName">
            </telerik:GridBoundColumn>
            <telerik:GridBoundColumn DataField="ChildGender" HeaderText="Child's Gender"
                SortExpression="ChildGender" CurrentFilterFunction="Contains" AutoPostBackOnFilter="true" UniqueName="ChildGender">
            </telerik:GridBoundColumn>
        </Columns>
    </MasterTableView>
</telerik:RadGrid>


york
Top achievements
Rank 1
 answered on 19 Jun 2011
1 answer
84 views
I am following the Demo Project

AsyncUpload / Ajax Processing


In the demo, it states to setup the RadAjax Manager as such:

    <telerik:RadAjaxManager ID="RadAjaxManager1" runat="server">
        <AjaxSettings>
            <telerik:AjaxSetting AjaxControlID="RadAjaxManager1">
                <UpdatedControls>
                    <telerik:AjaxUpdatedControl ControlID="Thumbnail" />
                </UpdatedControls>
            </telerik:AjaxSetting>
        </AjaxSettings>
    </telerik:RadAjaxManager>


Since my Asych Upload control is in a Content Page, I am using an RadAjaxManagerProxy.  My problem is if I set the AjaxContorlID to the Proxy's ID, I get a javascript error that I have nested Update Panels.  If I set it to the MasterPage's RadAjaxManager ID, I get a javascript error that ID can't be found.
    
Here is my code.

MasterPage:
 
    <telerik:RadAjaxManager ID="RadAjaxManager1" runat="server" ClientIDMode="Static"
        DefaultLoadingPanelID="ralpDefault">
        <ClientEvents OnRequestStart="centerLoadingPanel"></ClientEvents>
        <AjaxSettings>
        </AjaxSettings>
    </telerik:RadAjaxManager>
     
Content Page:
 
<telerik:RadAjaxManagerProxy ID="rampMyAccount" runat="server" ClientIDMode="Static">
    <AjaxSettings>
            <telerik:AjaxSetting AjaxControlID="RadAjaxManager1">
                <UpdatedControls>
                    <telerik:AjaxUpdatedControl ControlID="rbiAvatar" />
                </UpdatedControls>
            </telerik:AjaxSetting>
    </AjaxSettings>
</telerik:RadAjaxManagerProxy>

Peter Filipov
Telerik team
 answered on 19 Jun 2011
1 answer
104 views
Hi,

I put the Multiple File upload sample from The demo site to my project. And in my case, I tried to host the code inside a html table as below. However, it seems that the table cannot automatically expand to show the progress box. Something wrong in my css. Pls. kindly advise.

Thanks,
Elton

 

 

<table border="0" cellpadding="0" cellspacing="0" class="mainGTbl">

 

 

 

<colgroup>

 

 

 

<col width="100px" />

 

 

 

<col width="" />

 

 

 

</colgroup>

 

 

 

<tr>

 

 

 

<td>

 

 

 

<asp:Label ID="lblFileType" runat="server" EnableViewState="false"></asp:Label>:<span class="asterisk">*</span>

 

 

 

</td>

 

 

 

<td>

 

 

 

<telerik:RadComboBox ID="ddlFileType" runat="server" Width="300px"/>

 

 

 

</td>

 

 

 

</tr>

 

 

 

<tr>

 

 

 

<td>

 

 

 

<asp:Label ID="lblFileName" runat="server" EnableViewState="false"></asp:Label>:<span class="asterisk">*</span>

 

 

 

</td>

 

 

 

<td>

 

 

 

<div>

 

 

 

<telerik:RadProgressManager runat="server" ID="RadProgressManager" />

 

<%

 

-- For the purpose of this demo the files are discarded. In order to store the uploaded files permanently set the TargetFolder property to a valid location. --%>

 

 

 

 

<telerik:RadAsyncUpload runat="server" ID="AsyncUpload" MultipleFileSelection="Automatic" />

 

 

 

<telerik:RadProgressArea runat="server" ID="RadProgressArea" />

 

 

 

</div>

 

 

 

</td>

 

 

 

</tr>

 

 

 

<tr>

 

 

 

<td class="searchBtnTD" colspan="2">

 

 

 

<asp:Button ID="btnOK" runat="server" CssClass="srchBtn" OnClick="btnOK_Click" />

 

 

 

<asp:Button ID="btnCancel" runat="server" CssClass="srchBtn" OnClientClick="CloseCurrentRadWindow();" />

 

 

 

</td>

 

 

 

 

</tr>

 

 

 

</table>

 

Peter Filipov
Telerik team
 answered on 19 Jun 2011
4 answers
130 views
Hi,

I used to work with Telerik's controls some time ago, but after a few years of gap it seems I have forgotten some...

I have a Grid bound to a List<myTypeClass>. When I click on Edit/Delete, in the event handlers (RadGrid1_UpdateCommand and RadGrid1_DeleteCommand) I can't seem to figure out how to get the item that was edited/deleted.
I have custom stored procudures doing all the CRUD operations and to delete an item, for example, I need to know it's ID (which is one of the properties of the items in the list.
Any idea?
Any ideas are much appreciated
v
Viktor Takacs
Top achievements
Rank 2
 answered on 18 Jun 2011
2 answers
186 views
Hi..

How can i reload the TreeView using javascript in client side..?
sumither
Top achievements
Rank 1
 answered on 18 Jun 2011
1 answer
49 views
Hi, im building a forum like website with 3 tables, (Topics, Threads & Messages). iv got 3 forms with the same names. I would like to pass the primary key of one table (Topic) on the 1st form to link up with the relevant Threads on the Threads form. Here is my code below on the topics form.

 <Columns>
        <telerik:GridHyperLinkColumn DataTextField="Name"
            DataNavigateUrlFields="TopicID" 
            DataNavigateUrlFormatString= "Threads.aspx?TopicID={0}" ItemStyle-Font-Bold="true" />
        <telerik:GridHyperLinkColumn DataNavigateUrlFields="TopicID" 
        DataNavigateUrlFormatString="Threads.aspx?TopicID={0}" HeaderText="Topic" />
  </Columns>

The primary key does get passed as i can see it in the address bar but how do i retrieve it on the threads form?

Thanks in advance
Katlego
Top achievements
Rank 1
 answered on 18 Jun 2011
1 answer
97 views
Hello All,

My one of client had licensed version of Telerik Version 2007.2.1107.0.

In new version of telerik controls we have below attribute.

EnableEmbeddedSkins ="false"

any one have any idea how to stop style coming from web resource in Telerik Version 2007.2.1107.0.?

Thanks,
Kalpesh
Kalpesh V
Top achievements
Rank 1
 answered on 18 Jun 2011
1 answer
96 views
I need to find a control that's contained in a Template column when I get into a RowDrop event.  The control is in the DraggedItem object, and is always null.  Any suggestions?

 Dim index As Integer = CInt(e.DraggedItems(0).ItemIndex)
 Dim oList As DropDownList = CType(RadGrid1.Items(index).FindControl("oList"), DropDownList)
 Dim s As String = oList.SelectedValue

Thanks,
Alex
Shinu
Top achievements
Rank 2
 answered on 18 Jun 2011
7 answers
395 views
Hi All,
     I have one radgrid in that i have checkboxes,raddatepicker and radnumerictextbox.
     Attached is the screenshot of my radgrid.
    When i select raddatepicker i need to fill Percent complete radnumerictextbox with 100,completed checkbox checked
    and 99% complete checkbox uncheck and visible false on client side only.

 aspx page
 -----------------
<
telerik:RadGrid ID="RadGrid1" Skin="WebBlue" runat="server" AllowFilteringByColumn="true"
                    AutoGenerateColumns="false" ShowStatusBar="True" GridLines="None"
                    AllowPaging="true" PageSize="20" AllowSorting="True" onitemdatabound="RadGrid1_ItemDataBound">
                <MasterTableView GroupLoadMode="Client">
               <Columns>
                     <telerik:GridTemplateColumn UniqueName="Complete" HeaderText="Completed" AllowFiltering="false">
                        <ItemTemplate>
                            <asp:Panel ID="Panel1" runat="server" Width="2px">
                                <asp:CheckBox ID="chkComplete" runat="server"/>
                            </asp:Panel>
                        </ItemTemplate>
                    </telerik:GridTemplateColumn>
                     <telerik:GridTemplateColumn UniqueName="gridActFinish" HeaderText="Actual Finish" AllowFiltering="false">
                     <ItemTemplate>
                       <telerik:RadDatePicker ID="actfinish" runat="server" Width="100px" MaxDate='<%# Convert.ToDateTime(Eval("early_start_display")).ToString("dd/MMM/yyyy") %>'
                       Calendar-ShowOtherMonthsDays="false" Calendar-ShowRowHeaders="false" DbSelectedDate='<%# Bind("actual_finish") %>' DateInput-DateFormat="MM/dd/yyyy">
                       <ClientEvents OnDateSelected ="actfinish_OnDateSelected" >
                       </ClientEvents>
                       </telerik:RadDatePicker>
                     </ItemTemplate>
                    </telerik:GridTemplateColumn>
                  <telerik:GridTemplateColumn UniqueName="perComplete" HeaderText="99% Complete" AllowFiltering="false">
                        <ItemTemplate>
                            <asp:Panel ID="Panel2" runat="server">
                                <asp:CheckBox ID="Chkbox" runat="server"/>
                            </asp:Panel>
                        </ItemTemplate>
                    </telerik:GridTemplateColumn>
                    <telerik:GridTemplateColumn UniqueName="perComplete" HeaderText="Percent Complete" AllowFiltering="false">
                     <ItemTemplate>
                       <telerik:radnumerictextbox id="pct" runat="server" text='<%#Eval("pct") %>' minvalue="0" maxvalue="100" width="50px" FocusedStyle-BackColor="Yellow" NumberFormat-DecimalDigits="0">
                           <numberformat allowrounding="true" decimaldigits="4"/> 
                       </telerik:radnumerictextbox>
                     </ItemTemplate>
                    </telerik:GridTemplateColumn>
                       </Columns>
                </MasterTableView>
                </telerik:RadGrid>

  javascript
  --------------------------
  function actfinish_OnDateSelected(sender, args) {

               var rdgrid = $find("<%=RadGrid1.ClientID %>");
               var cell = sender.get_element().parentNode.parentNode;
               var index = cell.parentNode.rowIndex;
               var MasterTable = rdgrid.get_masterTableView();
               var row = MasterTable.get_dataItems()[index - 3]; //getting row
               var tbxAdopted = row.findControl("pct").set_value(100); //getting value of TextBox 'tbxAdopted'
               var checkbox = row.findControl("chkComplete");
               checkbox.checked = true;
           }
 in this action i am successfully filling value 100 in radnumerictextbox but i can't check the checkbox.

Thanks in advance, Please help me this senario on client side only.

Thanks,
Nagendra.
Nagendra
Top achievements
Rank 1
 answered on 18 Jun 2011
1 answer
259 views
How can I display an htmlcode inside a colum?

I have this:

<telerik:GridDropDownColumn
                                                    UniqueName="elementocostosrowid"
                                                    DataField="elementocostosrowid"
                                                    HeaderText="Categoria -<br />Elemento Costos" DataSourceID="sqlElementoCosto" ListTextField="dummy2"
                                                    ListValueField="rowid" SortExpression="elementocostosrowid"
                                                    DropDownControlType="DropDownList">
                                                </telerik:GridDropDownColumn>
 
 
<asp:SqlDataSource ID="sqlElementoCosto" ConnectionString="<%$ ConnectionStrings:GolosaNETConnectionString %>"
                                        ProviderName="System.Data.SqlClient" SelectCommand="SELECT a.rowid,b.descripcion + '[' + CONVERT(varchar(5),b.categoria)+']<br />' + a.descripcion + '[' + CONVERT(varchar(5),a.elementocostos)+']' as dummy2 FROM tbl01ElementoCostos a, tbl01ElementoCostosCategoria b WHERE a.elementocostoscategoriarowid=b.rowid" runat="server">
                                    </asp:SqlDataSource>

I need to render the "<br />" tag generated by the sqldatasource. I see the text <br /> in the grid, instead of the break.
Shinu
Top achievements
Rank 2
 answered on 18 Jun 2011
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?