Telerik Forums
UI for ASP.NET AJAX Forum
0 answers
81 views
Hello! I'm having this problem (I need at the click of a button to save the file on the client side. The button is in editformsettings in Grid! 
<asp:Button ID="ButSave" runat="server" Text="Save" CommandName="SaveAnket"/> 
Grid event! 
 
void Grid_ItemCommand (object sender, GridCommandEventArgs e) 
        

                
if (e.CommandName == "SaveAnket") 
                

                    
SaveBlankOnClient (); 
                

       

 
protected void SaveBlankOnClient () 
        

            
string filename = "TextFile.txt"; 
            
string longPath = MapPath (filename); 
            
Response.ContentType = "APPLICATION / OCTET-STREAM"; 
            
string disHeader = "Attachment; Filename = \" "+ filename +" \ ""; 
            
Response.AppendHeader ("Content-Disposition", disHeader); 
            
System.IO.FileInfo fileToDownload = new System.IO.FileInfo (longPath); 
            
Response.Flush (); 
            
Response.WriteFile (longPath); 
            
Response.End (); 
        


This operation does not work for me from the grid ... But in an ordinary button, it saves the file! I understand this is due to postback? 
How save file from the GridHelp please)))
Timyr
Top achievements
Rank 1
 asked on 21 Jul 2011
1 answer
77 views
We have a data intensive application and in one particular page, we have a Rad Grid display 180 columns/10rows of data. The page works well in IE8 and takes about 10 seconds to load, but the same page takes one and a half minute to load in IE7.

We know that IE7 Javascript is slower than IE8, but the difference in rendering times between these two browsers is very high. Are there any suggestions to improve the performance in IE7?
Maria Ilieva
Telerik team
 answered on 21 Jul 2011
2 answers
733 views
Hello,

I have come across a special scenario in the web app i am developing where I need to implement custom databinding. That is i need to bind my radgrid without using its NeedDataSource Event. I want something like this (traditional ASP.NET GridView way) :
myRadGrid.DataSource= myDataSet;
myRadGrid.DataBind();
And because of this, I also need to implement custom sorting, filtering and paging. 
It will be very nice if you could post a sample app with the code implementing all of the above requirements.
Ananth Kumar
Top achievements
Rank 2
 answered on 21 Jul 2011
9 answers
338 views
Hi,

I have a Grid which has a couple of aggregated footers. They even work OK.
However, I cannot get it to display localized values. This is the markup I'm using:
<telerik:GridNumericColumn DataField="Quantity" DataType="System.Int32" UniqueName="Quantity"
    FooterAggregateFormatString="<%$ Resources:strings,strNumberOfProducts%>" Aggregate="Sum">
    <HeaderStyle HorizontalAlign="Center" />
    <ItemStyle HorizontalAlign="Right" Width="50" />
</telerik:GridNumericColumn>
It correctly picks up the default (English) string but never picks up the localized version - although all the other parts of the grid appear localized.
I even tried to set the Culture property of the grid, but no luck.

Any idea on what I'm doing wrong?

v
Daniel
Telerik team
 answered on 21 Jul 2011
0 answers
119 views
Hi,

I'm evaluating the RadGrid control and I have problems with filters.

I have a datetime column and I want to add a filter for filtering between two dates. If I use a GridDateTimeColumn I can use a RadDatePicker in the filter, but only for one date (not a range).

After studying the sample 'Filtering range with RadDatePicker instances in a custom filtering column' you provide in the code library (code library article), I think it could be a solution.

I've used the sample code to create in my app a custom templated column and the filtering process works fine, but there is a problem:
    - I choose two dates in the combo and apply the filter, the filtering works fine.
    - If I apply the filter of another column (without clearing the filter applied to datetime), the datetime filter is cleared and only remains the filter of the other column.

How can I apply filters in other columns after datetime filtering without loosing the datetime filter?

Thanks in advance,
John.
john
Top achievements
Rank 1
 asked on 21 Jul 2011
0 answers
220 views

We identified several issues with our new Upgrade Wizard shortly after our Q2 2011 release.

The following circumstances are known to cause issues when using the Upgrade Wizard:

  • Having any invalid references in your project (marked with a warning sign in Visual Studio)
  • Having COM references in your project
  • Holding a project reference to a project which has not yet been built
  • Holding a project reference to a project whose output assembly name differs from the project's name

All of the above issues have already been addressed and an update has been released through the Visual Studio Online Gallery:
Telerik WebUI VSExtensions

You should be able to use the Visual Studio 2010 Extension Manager to download the update.


In case you are using Visual Studio 2008 and cannot get updates through the Visual Studio Online Gallery, you will be able to benefit the update when our next Service Pack release.

Best regards,
The Telerik Team

Telerik Admin
Top achievements
Rank 1
Iron
 asked on 21 Jul 2011
10 answers
1.0K+ views
I have a grid that contains a detail table for each record. Inside the detail table I have two commands. I handle the 

ItemCommand event, in which I execute a stored procedure depending on the command name and argument. So far so good. The issue is I can't seem to find a way to rebind the detail table, so when the page refreshes for the user they see the results. I have tried various things, but none seem to work. If I click refresh on the detail table then the detail table collapses. (Note: I need to try as hard as possible to do this via a stored procedure - there is auditing code, etc. inside of it).

Any help would be greatly appriciated.

Thanks,
Kent

        switch (e.CommandName)  
        {  
            case "terminate" :  
                db = new CasprDataContext();  
                mgrRoleID = int.Parse(e.CommandArgument.ToString());  
 
                //TEST ONE:  
                //mgrRole = db.EICPMgrRoles.Single(mr => mr.MgrRoleGID == mgrRoleID);  
                //mgrRole.RoleEndDate = DateTime.Now;  
                //db.SubmitChanges();  
 
                //TEST TWO (preferred):  
                //execute stored procedure  
                db.sp_UpdateManagerRole_End(mgrRoleID);  
 
                //TEST TWO-A:  
                //Rebind the details table  
                //dataItem.DataBind();  
 
                //TEST TWO-B:  
                managersGrid.MasterTableView.DetailTables[0].Rebind();  
                break;  
            case "restore" :  
                db = new CasprDataContext();  
                mgrRoleID = int.Parse(e.CommandArgument.ToString());  
 
                //TEST ONE:  
                //mgrRole = db.EICPMgrRoles.Single(mr => mr.MgrRoleGID == mgrRoleID);  
                //mgrRole.RoleEndDate = null;  
                //db.SubmitChanges();  
 
                //TEST TWO (preferred):  
                //execute stored procedure  
                db.sp_UpdateManagerRole_Restore(mgrRoleID);  
 
                //TEST TWO-A:  
                //Rebind the details table  
                //dataItem.DataBind();  
 
                //TEST TWO-B:  
                managersGrid.MasterTableView.DetailTables[0].Rebind();  
                break;  
        } 

<DetailTables> 
            <telerik:GridTableView DataKeyNames="MgrFID" DataSourceID="managerRolesDataSource" AllowFilteringByColumn="false" CommandItemDisplay="Bottom" EditFormSettings-ColumnNumber="2">  
                <ParentTableRelation> 
                    <telerik:GridRelationFields MasterKeyField="MgrGID" DetailKeyField="MgrFID" /> 
                </ParentTableRelation> 
                 <Columns> 
                    <telerik:GridBoundColumn DataField="MgrRoleGID" DataType="System.Int32"  ReadOnly="true" Visible="false" 
                        HeaderText="MgrRoleGID" SortExpression="MgrRoleGID" UniqueName="MgrRoleGID">  
                    </telerik:GridBoundColumn> 
                    <telerik:GridBoundColumn DataField="MgrFID" DataType="System.Int32" Visible="false"   
                        HeaderText="MgrFID" ReadOnly="True" SortExpression="MgrFID" UniqueName="MgrFID">  
                    </telerik:GridBoundColumn> 
                    <telerik:GridDropDownColumn DataField="RoleFID" DataType="System.Int32"   
                        DataSourceID="rolesDataSource" ListTextField="RoleDesc" ListValueField="RoleGID" 
                        HeaderText="Role" SortExpression="RoleFID"   
                        UniqueName="RoleFID">  
                        </telerik:GridDropDownColumn> 
                    <telerik:GridDropDownColumn DataField="RegionFID" DataType="System.Int32" EditFormColumnIndex="1" 
                        DataSourceID="regionsDataSource" ListTextField="RegionDesc" ListValueField="RegionGID" 
                        HeaderText="Region" SortExpression="RegionFID"   
                        UniqueName="RegionFID">  
                    </telerik:GridDropDownColumn> 
                    <telerik:GridBoundColumn DataField="RoleStartDate" DataType="System.DateTime"   
                        HeaderText="Start Date" SortExpression="RoleStartDate" ReadOnly="true" 
                        UniqueName="RoleStartDate">  
                    </telerik:GridBoundColumn> 
                    <telerik:GridBoundColumn DataField="RoleEndDate" DataType="System.DateTime"  ReadOnly="true" 
                        HeaderText="End Date" SortExpression="RoleEndDate" UniqueName="RoleEndDate">  
                    </telerik:GridBoundColumn> 
                    <telerik:GridTemplateColumn UniqueName="actions">  
                        <ItemTemplate> 
                            <asp:LinkButton runat="server" CommandName="terminate" CommandArgument='<%# Eval("MgrRoleGID") %>' Visible='<%# Eval("RoleEndDate") == null ? true : false %>'>Terminate</asp:LinkButton> 
                            <asp:LinkButton runat="server" CommandName="restore" CommandArgument='<%# Eval("MgrRoleGID") %>' Visible='<%# Eval("RoleEndDate") == null ? false : true %>'>Restore</asp:LinkButton> 
                        </ItemTemplate> 
                    </telerik:GridTemplateColumn> 
                </Columns> 
            </telerik:GridTableView> 
        </DetailTables> 

<asp:LinqDataSource ID="managersDataSource" runat="server"   
    ContextTypeName="Caspr.CasprDataContext" OrderBy="MgrLastName, MgrFirstName"   
    TableName="EICPMgrs" EnableInsert="True" EnableUpdate="True">  
</asp:LinqDataSource> 
<asp:LinqDataSource ID="managerRolesDataSource" runat="server"   
    ContextTypeName="Caspr.CasprDataContext" TableName="EICPMgrRoles"   
    Where="MgrFID == @MgrFID" EnableInsert="True"   
    oninserting="managerRolesDataSource_Inserting">  
    <WhereParameters> 
        <asp:SessionParameter Name="MgrFID" Type="Int32" SessionField="MgrFID" DefaultValue="0" /> 
    </WhereParameters> 
</asp:LinqDataSource> 
<asp:LinqDataSource ID="rolesDataSource" runat="server"   
    ContextTypeName="Caspr.CasprDataContext" OrderBy="RoleDesc"   
    Select="new (RoleDesc, RoleGID)" TableName="EICPRoles">  
</asp:LinqDataSource> 
<asp:LinqDataSource ID="regionsDataSource" runat="server"   
    ContextTypeName="Caspr.CasprDataContext" OrderBy="RegionDesc"   
    Select="new (RegionGID, RegionDesc)" TableName="EICPRegions">  
</asp:LinqDataSource> 
 
Sebastian
Telerik team
 answered on 21 Jul 2011
2 answers
101 views

Hi ,
can we add client side operation on grid as i want the following functionality in grid

can we add empty rows at client side ?
can we add news rows at client side  Programatically ?
Can we update existing row in clietn side Programatically ?
can we delete row at clietn sidte programatically ?

can user add news rows at client so that user could add data himself manually in row from UI  ?
can user update a row at client side manually from UI ?

after performing these operations on client side we want to process final data in grid on server.

if thsee functionalites are there in telerik grid or we can add them then pleae provide a sample application.
hafizmsuleman@gmail.com
Top achievements
Rank 1
 answered on 21 Jul 2011
8 answers
159 views
I've got a radconfirm being displayed by the OnClientClick event of a LinkButton.  The callback gets initiated by "OK", "Cancel", and the window close on Firefox, but IE8 only fires it when I close the dailog box ("OK" and "Cancel" do nothing).  We haven't updated our control set since Q2 2009, so I wonder if this was a bug that one of the later version introduced?

I'm using Telerik RadControls for ASP.NET AJAX 2010.2.929.35 under the .NET 3.5 framework.
Dominic
Top achievements
Rank 1
 answered on 21 Jul 2011
1 answer
76 views
Where I can find an example of n-layered application using RadGrid? Better in a ddd architecture using entity framework and poco or ste entity? Thanks.
Iana Tsolova
Telerik team
 answered on 21 Jul 2011
Narrow your results
Selected tags
Tags
+? more
Top users last month
Jay
Top achievements
Rank 3
Iron
Iron
Iron
Benjamin
Top achievements
Rank 3
Bronze
Iron
Veteran
Radek
Top achievements
Rank 2
Iron
Iron
Iron
Bohdan
Top achievements
Rank 2
Iron
Iron
Richard
Top achievements
Rank 4
Bronze
Bronze
Iron
Want to show your ninja superpower to fellow developers?
Top users last month
Jay
Top achievements
Rank 3
Iron
Iron
Iron
Benjamin
Top achievements
Rank 3
Bronze
Iron
Veteran
Radek
Top achievements
Rank 2
Iron
Iron
Iron
Bohdan
Top achievements
Rank 2
Iron
Iron
Richard
Top achievements
Rank 4
Bronze
Bronze
Iron
Want to show your ninja superpower to fellow developers?
Want to show your ninja superpower to fellow developers?