Your Privacy Matters: We use our own and third-party cookies to improve your experience on our website. By continuing to use the website we understand that you accept their use. Cookie Policy
90
WebHierarchicalDataGrid Upate error Column is read only
posted

Hello,

I am using a drop down list provider ig:DropDownProvider to edit a cell in the top level band of a ig:WebHierarchicalDataGrid.

I am using Auto CRUD, and a button to cause a post back.

When an edit is made and the button clicked I get an error:

Exception information:
    Exception type: System.Data.ReadOnlyException
    Exception message: Column 'DelegateJP' is read only.

 Stack trace:    at Infragistics.Web.UI.GridControls.GridBot.LoadAdditionalClientState(Object state)
   at Infragistics.Web.UI.GridControls.ContainerGridBot.LoadAdditionalClientState(Object state)
   at Infragistics.Web.UI.Framework.RunBot.HandleRaisePostDataChangedEvent()
   at Infragistics.Web.UI.GridControls.GridBot.HandleRaisePostDataChangedEvent()
   at Infragistics.Web.UI.GridControls.ContainerGrid.RaisePostDataChangedEvent()
   at System.Web.UI.Page.RaiseChangedEvents()
   at System.Web.UI.Page.ProcessRequestMain(Boolean includeStagesBeforeAsyncPoint, Boolean includeStagesAfterAsyncPoint)

If I just refresh the page the error disappears and you can see that the edit was saved.

The DelegateJP column property is NOT marked ReadOnly = true. If it were, the drop down list would not appear when you click on the cell.

It is not an error on the data base server because the update is made, as can be seen after refreshing the page to make the error message go away.

This is the editing core mark up:

<ig:EditingCore >
                <Behaviors>
                    <ig:CellEditing>
                        <ColumnSettings>
                            <ig:EditingColumnSetting ColumnKey="DelegateJP"
                                EditorID="whdgAuditTracking_DropDownProvider1" />
                            <ig:EditingColumnSetting ColumnKey="Comments"
                                EditorID="whdgAuditTracking_TextEditorProvider1" />
                            <ig:EditingColumnSetting ColumnKey="Quarter" ReadOnly="True" />
                            <ig:EditingColumnSetting ColumnKey="RPName" ReadOnly="True" />
                            <ig:EditingColumnSetting ColumnKey="RPjp" ReadOnly="True" />
                            <ig:EditingColumnSetting ColumnKey="GroupingName" ReadOnly="True" />
                            <ig:EditingColumnSetting ColumnKey="Status" ReadOnly="True" />
                            <ig:EditingColumnSetting ColumnKey="DelegateName" ReadOnly="True" />
                        </ColumnSettings>
                        <EditModeActions MouseClick="Single" />
                    </ig:CellEditing>
                </Behaviors>
            </ig:EditingCore>

This is the editor provider:

<ig:DropDownProvider ID="whdgAuditTracking_DropDownProvider1">
                <EditorControl
                    DropDownContainerMaxHeight="200px"
                    EnableAnimations="False"
                    TextField="FULL_NAME_LAST"
                    ValueField="DelJP"
                    EnableDropDownAsChild="False"
                    DataSourceID="sdsGetDelegates"
                    
                    StyleSetName="ElectricBlue"
                    DropDownOrientation="BottomRight"
                    DisplayMode="DropDownList"
                    CssClass="txtAlignLeft"
                      >
                    <DropDownItemBinding TextField="FULL_NAME_LAST" ValueField="DelJP" />
                </EditorControl>
            </ig:DropDownProvider>

Unfortunately we are still on version 9 here. Is this a known error in that version?

Thanks very much,

-Bill

Parents
No Data
Reply
  • 90
    posted

    I found the problem. My grid column mark up was this:

     

     

    <

     

     

    ig:BoundDataField DataFieldName="DelegateJP" Key="DelegateJP"

    >

     

     

    <Header Text="Delegate"

    />

     

     

    </ig:BoundDataField

    >

    But is should have been this:

    <

     

    ig:BoundDataField DataFieldName="DelegateName" Key="DelegateJP" >

     

    <Header Text="Delegate" />

     

    </ig:BoundDataField>

Children
No Data