Grid is not binding after multiple API Call

Hi 

I am trying to bind the Grid control after multiple time api call. Data is coming in list datasource, But it is not displaying on grid control. Am i missing any things ?


@if (@liscustomerVMs != null)

{

    <SfGrid DataSource="@liscustomerVMs" ID="Grid" @ref="gridObj"

            AllowPaging="true">

        <GridPageSettings PageSize="10"></GridPageSettings>

        <GridColumns>

            <GridColumn Field=@nameof(objCustVM.custno)

                        HeaderText="custno" TextAlign="@TextAlign.Left" Width="100">

            </GridColumn>

            <GridColumn Field=@nameof(objCustVM.address1)

                        HeaderText="Address" TextAlign="@TextAlign.Left" Width="100">

            </GridColumn>

            <GridColumn Field=@nameof(objCustVM.city)

                        HeaderText="City" TextAlign="@TextAlign.Left" Width="100">

            </GridColumn>

            <GridColumn Field=@nameof(objCustVM.state)

                        HeaderText="State" TextAlign="@TextAlign.Left" Width="100">

            </GridColumn>

            <GridColumn Field=@nameof(objCustVM.zip)

                        HeaderText="Zip" TextAlign="@TextAlign.Left" Width="100">

            </GridColumn>

            <GridColumn Field=@nameof(objCustVM.MyFLAcctNo)

                        HeaderText="MyFlacctNo" TextAlign="@TextAlign.Left" Width="100">

            </GridColumn>

            <GridColumn Field=@nameof(objCustVM.chargeok)

                        HeaderText="Chargeok" TextAlign="@TextAlign.Left" Width="100">

            </GridColumn>

            <GridColumn Field=@nameof(objCustVM.CreditHold)

                        HeaderText="CreditHold" TextAlign="@TextAlign.Left" Width="100">

            </GridColumn>

            <GridColumn Field=@nameof(objCustVM.AccountClosed)

                        HeaderText="AccountClosed" TextAlign="@TextAlign.Left" Width="100">

            </GridColumn>

            <GridColumn Field=@nameof(objCustVM.outOfBusiness)

                        HeaderText="OutOfBusiness" TextAlign="@TextAlign.Left" Width="100">

            </GridColumn>

        </GridColumns>

    </SfGrid>


}

>> In above code, I am getting  data liscustomerVMs collection, But it is rendering on grid Control.


2 Replies

CH chandradev July 29, 2021 03:09 PM UTC

I have fixed the issue.



RS Renjith Singh Rajendran Syncfusion Team July 30, 2021 08:58 AM UTC

Hi chandradev, 

Thanks for your update. We are glad to hear that you have resolved the reported problem. 

Please get back to us if you need further assistance. 

Regards, 
Renjith R 


Loader.
Up arrow icon