Create my own TagHelper including Chart component

Hello,

I'm trying to create my own TagHelper that needs to implement the Chart component of Syncfusion.
But when I'm processing the Syncfusion.EJ2.Charts.Chart object, on the line chart.Process(context, output); I'm getting an error "Object reference not set to an instance of an object.".

How can I create my own TagHelper including the Chart object of Syncfusion ?

Regards,

Julien.

Attachment: MyChartTagHelper_67596954.zip

4 Replies 1 reply marked as answer

SM Srihari Muthukaruppan Syncfusion Team January 14, 2021 10:16 AM UTC

Hi Julien, 
 
We have analyzed your query. From that we suggest you to use @addTagHelper *, Syncfusion.EJ2 in the _ViewImports.cshtml page to install our Syncfusion packages. We have also attached our documentation link for your reference. Please find the demo link below. 
 
 
If still this is not your exact requirement. Kindly share the use case scenario of the requested scenario for further analysis and provide you solution sooner. 
 
Regards, 
Srihari 



JG Julien Gambini January 15, 2021 08:30 AM UTC

Hello Srihari,

I already added Syncfusion in my ViewImports file, and I can use Syncfusion components easily without problems. That is not my question.

My question is to create my own tag helper inheriting from Syncfusion components.

Because, for example, on the chart component, I want to dynamically add series. My datasource can contain several series. The user can choose how much series he wants to display. And as far as I understand, you must specify every serie in the Syncfusion component, you can't do it dynamically.

Regards,

Julien.



SM Srihari Muthukaruppan Syncfusion Team January 18, 2021 11:34 AM UTC

Hi Julien, 
 
Sorry for the inconvenience. 
 
We have analyzed your query. Regarding the query of “create my own tag helper inheriting from Syncfusion components” we have forwarded the query to the concern team we will update the status within two business days (January 20 2021). We appreciate your patience until then. Based on your requirement we have also attached the documentation link for adding and removing series dynamically for your reference. 
 
 
Let us know if you have any concerns. 
 
Regards, 
Srihari M 



SM Srihari Muthukaruppan Syncfusion Team January 20, 2021 02:33 PM UTC

Hi Julien, 
 
Please refer to the below documentation for creating a custom Tag Helper. Please find the link below 
 
 
And as stated earlier we have also attached the documentation link for adding and removing series dynamically for your reference.  
  
 
If you still face this issue. kindly revert us with the following information which will be more helpful for further analysis and provide you the solution sooner.  
  1. Try to share the runnable project.  
  2. Share the details if you have done any other customization.
Regards, 
Srihari M 


Marked as answer
Loader.
Up arrow icon