javascript - How to Remove Previously Drawn InfoVis Space Tree -


I am using InfoVis to create a space tree view in one of my projects. Since this is an interactive web site, space trees need to be re-established every time and the user has changed the preferences.
This requires the space tree to be completely cleaned and to pull a new tree again in one place. In addition, the charting area can be resized as the page size is different. For this, it is necessary to attract the Space Tree again.

Before drawing a new picture, I came across several issues while trying to clear the pre-prepared space tree. I am using the following code segment to clear the previous drawing, but it is failing badly.

  st.clearNodesInPath (); St.labels.clearLabels (true); St.canvas.clear ();   

If someone can guide me how to solve it it would be good because it is blocking my progress Thanks in advance.

Enter image details here < P>

This was resolved in the following way.

Even after clearing element data structures within the HTML div element of the InfoVis chart, there was a problem due to the path of the devil elements generated. Those who were previously shown clearly in the images attached.

It was resolved as follows.

  var list = document.getElementById ("idOfParentElement"); List.removeChild (list.childNodes [0]);   

Code Piece Parent Removes InfoVis element and it clears all the generated child elements. This will eventually clear the canvas object, where visualization will be prepared.

It solved my problem, hoping that it helps for the same problem.

Comments

Popular posts from this blog

php - PDO bindParam() fatal error -

logging - How can I log both the Request.InputStream and Response.OutputStream traffic in my ASP.NET MVC3 Application for specific Actions? -

java - Why my included JSP file won't get processed correctly? -