Grid Cell not keeping edit change

2 posts, 0 answers
  1. Mark
    Mark avatar
    5 posts
    Member since:
    Oct 2006

    Posted 11 Feb 2010 Link to this post

    I have a RadGridView control that is being populated from a WCF service and if I set the autogeneratecolumns=True, when I enter the cell and change the contents, it changes works fine; however if I set it to false it reverts back to the original content of the cell.   I want to be able to control which columns display

    My WCF service returns the data into a datatable.

             <telerik:RadGridView  Name="grd1" AutoGenerateColumns="False" Width="1000" Height="100" CanUserFreezeColumns="False"
                <telerik:RadGridView.Columns > 
                    <telerik:GridViewDataColumn DataMemberBinding="{Binding ItemCode}" Header="ISBN" UniqueName="ItemCode" /> 

    I tried adding the column in XAML and doing it in VB.NET and when autogen is false -- it won't keep the change.   

    Is there some other code behind that I need to do to make the cell change stay ?

            Dim VenCode As String 
            If cbVendor.SelectedValue = "*" Then VenCode = "%" Else VenCode = cbVendor.SelectedValue 
            Dim sqlCmd As String 
            sqlCmd = "SELECT TOP 100 PERCENT dbo.ToBeReturned.ItemCode , dbo.Inventory.Title as Description, " _ 
                    & "dbo.ToBeReturned.Qty, upper(RTRIM(Ltrim(dbo.ToBeReturned.RtnVendor))) as Vendor, dbo.ToBeReturned.Invoice, " _ 
                    & "dbo.ToBeReturned.InvoiceDt, dbo.ToBeReturned.Discount, dbo.ToBeReturned.Price as Cost, " _ 
                    & "UPPER(dbo.ToBeReturned.RtnVendor) as orgVendor FROM dbo.ToBeReturned " _ 
                    & "INNER Join dbo.Inventory ON dbo.ToBeReturned.ItemCode = dbo.Inventory.ItemCode Where Vendor Like '" & VenCode & "'" 
            '//ieData.AddPrm("@myKey", pType.pString, "ARC", True) 
            Dim column As New GridViewDataColumn() 
            column.DataMemberBinding = New Binding("ItemCode"
            column.Header = "ISBN" 
            column.UniqueName = "ItemCode" 
            Me.grd1.AutoGenerateColumns = False 
            grd1.ItemsSource = ieData.dt 

  2. Nedyalko Nikolov
    Nedyalko Nikolov avatar
    871 posts

    Posted 17 Feb 2010 Link to this post

    Hello Mark,

    I've tried to simulate the issue unfortunately to no avail. Since the described behavior sounds like bug, can you send me a sample project (based on Northwind database) which I can debug on my side? Thanks in advance.

    Sincerely yours,
    Nedyalko Nikolov
    the Telerik team

    Do you want to have your say when we set our development plans? Do you want to know when a feature you care about is added or when a bug fixed? Explore the Telerik Public Issue Tracking system and vote to affect the priority of the items.
Back to Top