Error when closing modal with sfcombox

Good morning,

I have a page that calls a query modal, using Syncfusion Dialogs - (NcmCestConsulta.razor) and this modal, when clicking on the edit or new button, calls another registration modal (NcmCestCadastro.razor);

This registration modal has an SfComboBox called "Imposto CFe", whose TItem is the class called "IcfeItem" and whose datasource is the object "IcfeList".

When closing the modal using the "X" or "Cancel" button, the error "Unhandled exception rendering component: Object reference not set to an instance of an object." occurs, referring to the type "Syncfusion. Blazor.DropDowns.SfDropDownList" and "Syncfusion.Blazor.DropDowns.SfComboBox", and also the "OnAfterRenderAsync" method, citing the "VitaWeb.Shared.NcmCest.IcfeItem" class in the error.

I would like your help to understand where the error is, because when closing the modal there should be no reference to this field or component.

Prints, source code and error log attached as .rar.

Thank you in advance.


Attachment: errors_sfcombobox_a43044f9.rar

1 Reply

YS Yohapuja Selvakumaran Syncfusion Team July 10, 2024 01:05 PM UTC

Hi alexandre trapp,


Thank you for reaching out to us. We have validated the reported issue and created a sample based on the shared information. The ComboBox is rendered inside the dialog, and after clicking on clear, there is no console error. Kindly check out the sample below for further reference.


Sample: https://blazorplayground.syncfusion.com/LZhpDQitTRiFsuSA




To help us replicate the reported issue on our end, we kindly request you to modify the shared sample to demonstrate the issue you are encountering.


For more information about the dialog component, please refer to the demos and documentation below:


Demo:  https://blazor.syncfusion.com/demos/dialog/default-functionalities?theme=fluent2


Documentation: https://blazor.syncfusion.com/documentation/dialog/getting-started-with-web-app



Regards,

Yohapuja S


Loader.
Up arrow icon