Telerik Forums
UI for ASP.NET AJAX Forum
1 answer
242 views
Hi,

I am creating several radgrids dynamically via my code at runtime and placing them accordingly within a dynamically created pageview on a page. How can I stop them from posting back to the page and still let the user page the grid? Is this even possible?

I have tried looking through your client-side api but I can't seem to just find a section about client-side paging. I have even tried dynamically creating an updatepanel, adding the grid its content template and then adding the panel to the controls of the pageview and still no joy.

Here is my code to create the grid:

RadGrid rgrdSection = new RadGrid(); 
rgrdSection.ID = "grd" + (i+1).ToString(); 
rgrdSection.AutoGenerateColumns = false; 
rgrdSection.AllowSorting = false; 
rgrdSection.Width = Unit.Percentage(97.0); 
rgrdSection.AllowMultiRowSelection = false; 
                rgrdSection.ShowStatusBar = true; 
                rgrdSection.AllowPaging = true;                 
                rgrdSection.PageSize = 8;                 
                rgrdSection.AlternatingItemStyle.BackColor = System.Drawing.ColorTranslator.FromHtml("#979EB8"); 
 
                // Add columns 
                GridBoundColumn boundColumn = new GridBoundColumn(); 
                boundColumn.DataField = "user_key_7"; 
                boundColumn.HeaderText = "Sub-Chapter"; 
                rgrdSection.MasterTableView.Columns.Add(boundColumn); 
 
                rgrdSection.PagerStyle.Mode = GridPagerMode.NumericPages; 
                rgrdSection.PagerStyle.Position = GridPagerPosition.TopAndBottom; 
                rgrdSection.ClientSettings.EnableRowHoverStyle = true; 
                rgrdSection.ClientSettings.EnablePostBackOnRowClick = false; 
                rgrdSection.ClientSettings.Selecting.AllowRowSelect = false; 



Any ideas?
Thanks,

Ian W
Veli
Telerik team
 answered on 08 Jul 2010
3 answers
125 views
Hi,

When we perform an action on an edited row all other edited rows are rebinded, their states are not persisted. So, how could we preserve other edited rows states ?

Thanks !

@loys
Yavor
Telerik team
 answered on 08 Jul 2010
1 answer
851 views
Hi,
i want to set the height if row.
i wrote like CS,
protected void RadGrid1_ItemDataBound(object sender, GridItemEventArgs e) 
    { 
        if (e.Item is GridDataItem) 
        { 
            GridDataItem item = (GridDataItem)e.Item; 
            item.Height = Unit.Pixel(10); 
        } 
    } 
 
but it is not working.reply me
Dimo
Telerik team
 answered on 08 Jul 2010
1 answer
113 views
Hi all
i am using 3- numeric text box in sequence . 
my java script code like this

               Client_radNumericA = '<%= txtLami_1.ClientID %>';
                Client_radNumericC = '<%= txtLami_3.ClientID %>';
                radNumericA = $find(Client_radNumericA);
                radNumericC = $find(Client_radNumericC);
                radNumericC._textBoxElement.value = parseFloat(radNumericA._textBoxElement.value).toFixed(2).toString();

when focus gone on "radNumericC " the value of "radNumericC " is clear.

any body have the solution?


Thanks in advance
Jagdish Prajapati


Dimo
Telerik team
 answered on 08 Jul 2010
1 answer
148 views

Hi,

I have 3 radtabs each one containing a radgrid. In the first tab you have all the to-be-classify registers, there can only be two types of registers ( A and R). So for example if you mark 10 registers on the first radgrid and classify them, the first radgrid rebinds (using the needDataSource event) and everything is fine, but if I change tab and look at any of the two other radgrids neither will be updated. I have to refresh the page if I want to see the changes.

In my code in the NeedDataSource event setting the DataSource for the 3 radgrids but only seems to be working for the selected radgrid (because if I change the classification from A to R in the second radgrid I wont see the registers that does not belong to this radgrid anymore but I don't see the changes on the R radgrid)

here is my code (I dont use any AjaxManager, all is being done only by Postbacks) 

Protected Sub setStatus(ByVal source As Object, ByVal e As Telerik.Web.UI.GridCommandEventArgs) Handles RadGridClientes.ItemCommand  
 
        If e.CommandName = "rejectStatus" Or e.CommandName = "approveStatus" Then  
            Dim item As Telerik.Web.UI.GridEditableItem = DirectCast(e.Item, Telerik.Web.UI.GridEditableItem)  
            Dim newStatus As String = "0"  
 
            If e.CommandName = "approveStatus" Then  
                newStatus = "A"  
            ElseIf e.CommandName = "rejectStatus" Then  
                newStatus = "R"  
            End If  
 
            updateRecord(item, newStatus)  
            Me.RadGrid1.Rebind()  
 
        End If  
    End Sub 

 Protected Sub RadGrid_NeedDataSource(ByVal source As Object, ByVal e As Telerik.Web.UI.GridNeedDataSourceEventArgs) Handles RadGrid1.NeedDataSource, RadGridA.NeedDataSource, RadGridR.NeedDataSource  
        Dim ws As New webService  
 
        RadGrid1.DataSource = wsNC.fillStatus("0")  
        RadGridA.DataSource = wsNC.fillStatus("A")  
        RadGridR.DataSource = wsNC.fillStatus("R")  
 
    End Sub 

Rosen
Telerik team
 answered on 08 Jul 2010
6 answers
297 views
Hi,
I have tried out your radprogressarea for feeding progress back to the client for long running server side processes and it works really well, what I was wondering is whether you have any way of updating eg. custom text boxes or populating grids using a similar method (I don't think ajax can do what I want to do)?
a good example of what I want to achieve would be a grid full of pc names where the client fires off a server side script to ping them, the replies (progress) would then update the grid in real time to show success or failure.
Tsvetoslav
Telerik team
 answered on 08 Jul 2010
0 answers
130 views

Hi All,

i have used RadMenu for open the Popup(Radpoup). i am using OnClientItemClicked event to open the RadWindow. This is working fine. Now i have added one Button called "Export to Excel" for exporting the data in Excel. This also woking fine. My issue is After the export, f i clicked the radmenu, the radwindow not working. but the event OnClientItemClicked fired correctly.

<asp:UpdatePanel ID="testPanel" runat="server">     
<contenttemplate>    
    
<radM:RadMenu ID="mnuImport" Width="90%" runat="server" Skin="Default2006" OnClientItemClicked="ImportPopup" CausesValidation="false">     
 <DefaultGroupSettings Height="160" Width="70" />                                                                              <Items>    
    <radM:RadMenuItem Text="Red" Value="Red">     
        <Items>    
            <radM:RadMenuItem Text="Red" Value="Red"></radM:RadMenuItem>    
            <radM:RadMenuItem Text="Blue" Value="Blue"></radM:RadMenuItem>    
            <radM:RadMenuItem Text="Yellow" Value="Yellow"></radM:RadMenuItem>    
            <radM:RadMenuItem Text="Orange" Value="Orange"></radM:RadMenuItem>    
        </Items>    
    </radM:RadMenuItem>                                                                        
   </Items>    
</radM:RadMenu>    
    
    
<asp:Button ID="btnExport" runat="server" Text="Export to Excel" CssClass="searchbutton" CausesValidation="false"/>       
    
</contenttemplate>    
<triggers>    
    <asp:PostBackTrigger ControlID="btnExport" /> <!-- if i comment this line, the Popup is working fine. but the export is not working -->       
</triggers>    
</asp:UpdatePanel>    
    
<div>    
  <radwindow:RadWindowManager ID="RadWindowManager1" runat="server" Skin="Vista" Behavior="Close, Move"    
      Height="300px" Width="500px" Modal="true">     
      <Windows>    
           <radwindow:RadWindow ID="radImport" runat="server" Title="Import" ReloadOnShow="true"      
                  Height="300px" Width="500px"  VisibleTitlebar="true" Skin="Vista"/>                                                  
           </Windows>    
  </radwindow:RadWindowManager>    
</div>    
    
    
    
function ImportPopup(sender, eventArgs)     
{     
             
        var selectedImportType = eventArgs.Item.Value;             
        window.radopen("../DocMgt/ImportPopup.aspx?ImportType=" + selectedImportType, 'radImport');     
        return false;     
}    
 

this is working fine if we never click export button. once we clicked the export button the events are fired correctly, but the rad window is not opened.

Let me know if any solutions.

Thanks in Advance,
Anand
Anand
Top achievements
Rank 1
 asked on 08 Jul 2010
1 answer
207 views
Hi all,

I have one RadToolBarButton: Show/Hide Filter. When I click the button, I want the Filter disappear or appear. I tried from client side, call RadGrid.MasterViewPage.showFilter/hideFilter(The method name maybe incorrect.). but it has a "flicker": at first it will show up the filter, but then it will disappear. So this make the page a little "flicker".
I tried from server side, when click the show/hide button, trigger the server side button click event. And change the property AllowFilteringByColumn to true or false. But this does not work for the frist and second click. And the RadGrid refreshed but the filter won't appear if I click Show Filter or Hide Fiter. The thrid click will work. I assuming that the RadGrid does not refresh correct. So I call the RadGrid.Rebind() method. But this time, another issue occur,
1) The filter disappear when the page load first.
2) click Show Filter, the filter will appear.
3) input some expression and the result get filtered, which is correct.
4) click Hide Filter, the filter disappear.
5) click the show filter again, The full list is displayed, but the previous filter expression is still in the textbox, which mean the expression does not be applied.

I thought it was because of the ViewState of the RadGrid, but when I disable the ViewState for the RadGrid, I encountered some other issues, which made me believe that the viewState could not be disabled.

How I can get rid of this? Does anyone has a solution for this?
Thanks in advance. Need urgent answer.
zxp
Top achievements
Rank 1
 answered on 08 Jul 2010
2 answers
93 views
Hi

Please treat this as very Urgent:

We've the telerik Grid (with 20 columns) with Grouping and static headers.
When we try to scroll horizontally the header column and row data is not aligned.

Pls Help.

Thanks,

Gopi
Gopinath
Top achievements
Rank 1
 answered on 08 Jul 2010
0 answers
124 views
Hello,

I have the following panelbar structure:

  • Header1
  1. Item1
  2. Item2
  3. Item3
  • Header2
  1. Item1
  2. Item2
  • Header3

The panel bar is set to FullExpandedItem. Now if Item2 is too long (listbox for example) the whole Childgroup of header1 has scroll bar.
What I need is Item1 to always be there and only scroll Item2 and Item3 in the same container.

Can this be done ? Some kind of "Static" item like static headers in the grid.


Roland
Roland
Top achievements
Rank 1
 asked on 07 Jul 2010
Narrow your results
Selected tags
Tags
+? more
Top users last month
Jake
Top achievements
Rank 1
RBarnes
Top achievements
Rank 1
Iron
Iron
Rami
Top achievements
Rank 1
Iron
Veteran
Nathan
Top achievements
Rank 1
Kumeri
Top achievements
Rank 1
Iron
Veteran
Iron
Want to show your ninja superpower to fellow developers?
Top users last month
Jake
Top achievements
Rank 1
RBarnes
Top achievements
Rank 1
Iron
Iron
Rami
Top achievements
Rank 1
Iron
Veteran
Nathan
Top achievements
Rank 1
Kumeri
Top achievements
Rank 1
Iron
Veteran
Iron
Want to show your ninja superpower to fellow developers?
Want to show your ninja superpower to fellow developers?