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
175
Getting Runtime Exception on WHDG when expanding row.
posted

My WHDG uses a natural key (varchar)as the pk and some pk data have spaces in them ( e.g. "Product Line A").
The related hierarchical child product data use int surrogate keys.  When I attempt to expand rows where the pk has a space in it, I get the following pop-up error:  (Rows with no space expand normally.

<ig:WebHierarchicalDataGrid ID="hdgPrdln" runat="server" Height="350px" Width="640px"
                AutoGenerateBands="False" AutoGenerateColumns="False" DataKeyFields="IproPrdlnNM"
                DataMember="odsPrdln_DefaultView" DataSourceID="hdsPrdln" Key="odsPrdln_DefaultView">
                <ClientEvents DoubleClick="hdgPrdln_DoubleClickPostBack" />
                <Columns>
                    <ig:BoundDataField Hidden="false" DataFieldName="IproPrdlnNM" Key="IproPrdlnNM"  >
                        <Header Text="Product Line" />
                    </ig:BoundDataField>
                </Columns>
                <Bands>
                    <ig:Band AutoGenerateColumns="false" DataMember="odsPrd_DefaultView" Key="odsPrd_DefaultView"
                        DataKeyFields="SrcSysPrdIDKey">
                        <Columns>
                            <ig:BoundDataField Hidden="false" Width="30px" DataFieldName="SrcSysPrdIDKey" Key="SrcSysPrdIDKey">
                                <Header Text="ID" />
                            </ig:BoundDataField>
                            <ig:BoundDataField Hidden="false" DataFieldName="SrcSysPrdNM" Key="SrcSysPrdNM">
                                <Header Text="Product Name" />
                            </ig:BoundDataField>
                            <ig:BoundDataField Hidden="false" DataFieldName="SrcSysNM" Key="SrcSysNM">
                                <Header Text="Source System" />
                            </ig:BoundDataField>
                            <ig:BoundDataField Hidden="false" DataFieldName="SrcSysUniqID" Key="SrcSysUniqID">
                                <Header Text="Unique ID" />
                            </ig:BoundDataField>
                        </Columns>
                    </ig:Band>
                </Bands>
                <Behaviors>
                    <ig:Activation>
                    </ig:Activation>
                    <ig:Selection CellClickAction="Row" RowSelectType="Single">
                    </ig:Selection>
                    <ig:EditingCore AutoCRUD="False">
                        <Behaviors>
                        </Behaviors>
                    </ig:EditingCore>
                </Behaviors>
            </ig:WebHierarchicalDataGrid>

<ig:WebHierarchicalDataSource ID="hdsPrdln" runat="server">
                <DataViews>
                    <ig:DataView ID="odsPrdln_DefaultView" DataMember="DefaultView" DataSourceID="odsPrdln" />
                    <ig:DataView ID="odsPrd_DefaultView" DataMember="DefaultView" DataSourceID="odsPrd" />
                </DataViews>
                <DataRelations>
                    <ig:DataRelation ChildColumns="IproPrdlnNM" ChildDataViewID="odsPrd_DefaultView"
                        ParentColumns="IproPrdlnNM" ParentDataViewID="odsPrdln_DefaultView" />
                </DataRelations>
            </ig:WebHierarchicalDataSource>
            <asp:ObjectDataSource ID="odsPrdln" runat="server" SelectMethod="GetMultipleAsObject"
                TypeName="ITSMR_Data.IproPrdlnClass"></asp:ObjectDataSource>
            <asp:ObjectDataSource ID="odsPrd" runat="server" SelectMethod="GetMultipleAsObject"
                TypeName="ITSMR_Data.PrdPrdlnHierarchyROClass"></asp:ObjectDataSource>

Not sure what I may be missing. Thanks for your help!        

Jon

Parents
No Data
Reply Children
No Data