We use cookies to give you the best experience on our website. If you continue to browse, then you agree to our privacy policy and cookie policy. Image for the cookie policy date
close icon

Need help with the treemap control

Hi,

I trying to use the treemap control to show sales data with drilldown option for Android app. I tried to simulate the sample program and bind the data but i have two problems:

  1. multilevel drilldown does not happen:
    1. I use TreeMapFlatLevel but it does not work if there are more than one levels. When the first level is drilled down, the second levels elements are blank (a white space is shown). Whereas, if I have only one level, then upon drilling down the leaf elements are shown.

    For example, My levels are Division (Cardiology) , Zone (SouthZone), Region (Chennai), Territory (Adyar)

    If I set only one level (division/zone/region), then upon drilling down it shows the territories

    If I set more then one level (L1 division; L2 Zone and L3 Region) Upon databinding the Division level is shown. When i drilldown the division, the zone elements are not shown.

      2. A Null pointer reference is thrown if I define itemtemplate (even if don't bind any data within the template). I have commented that piece in the sample. When i enable it , the error is thrown. Also, is it possible to have an itemtemplate similar to the screenshot attached?

I'm not sure what i'm missing.


File attachments:


  1. treemap.zip (code sample and screenshots of the drilldown)

Attachment: treemap_c4ed809e.zip

7 Replies

VO Vishal Omprasad Syncfusion Team November 22, 2022 02:41 PM UTC

Query 1: multilevel drilldown does not happen

We have tested your reported problems using your sample provided with our own data. But, we were unable to reproduce the issue you specified and we can drill down more than one levels. We have attached the sample for your reference. If the sample we provided has not met your requirement, you can modify that sample and share it with us.


Query 2: A Null pointer reference is thrown

We can reproduce the issue and currently validating our source. We will update you the status by tomorrow.





Attachment: TreeMap_bb0250c7.zip


SK Santhosh Kumar November 23, 2022 05:50 AM UTC

Hi Vishal,

The sample works alright but for some reason it is not working in my solution. I copy pasted the code from your sample and even that doesn't work in my solution. I'm using version 20.3.0.57 from the Nuget package. Does it have something to do with this?


Thanks

Santhosh



ET Eswaran Thirugnanasambandam Syncfusion Team November 25, 2022 01:14 AM UTC

Hi Santhosh,


Query 1: Sample works alright but for some reason it is not working in my solution

Since we are not aware of the actual scenario, we are unable to replicate the reported problem from our side. Can you please revert us by modifying the previously shared sample based on your application scenario? This will allow us to assist you with a better solution as soon as possible.


Query 2: A Null pointer reference is thrown

Sorry for the inconvenience, our development team need some more time to validate the reported problem and we will update further details by tomorrow.


Regards,

Eswaran



SK Santhosh Kumar November 25, 2022 04:47 AM UTC

Dear Eswaran,

Your sample matches with my application scenario and your project works on my machine. But for some weird reason it doesn't work on my project. Even if I copy paste your sample into my project it does not work. At this moment I'm not able to figure out what is going wrong with my project. Let me take some time and work on different sample applications and see if it works. I will update here if I find something. We can keep it on hold for now as this is something that seems to be on my end.

Please update me when the second problem is fixed.


Thank you for your support!


Santhosh



PR Preethi Rajakandham Syncfusion Team November 28, 2022 07:35 AM UTC

Hi Santhosh,

We will wait to hear from you.

Regards,

Preethi R



ET Eswaran Thirugnanasambandam Syncfusion Team December 2, 2022 02:25 PM UTC

Query: A Null pointer reference is thrown

We checked the reported problem “NRE exception occurs when using item template for flat level tree nodes” with our source and logged a bug report for this. You can keep track of the bug through the feedback portal below.


https://www.syncfusion.com/feedback/39575

NOTE: The provided feedback link is private, and you need to log in to view it.


We will include the fix in our upcoming weekly NuGet, which is expected to be rolled out on December 13, 2022. If you have any more specifications, precise replication procedures, or a scenario to be tested, you can add it as a comment in the portal.


Disclaimer: Inclusion of this solution in the weekly release may change due to other factors including but not limited to QA checks and works reprioritization.



ET Eswaran Thirugnanasambandam Syncfusion Team December 14, 2022 05:41 AM UTC

We have fixed the reported problem NRE exception occurs when using item template for flat level tree nodesand the fix is included in our weekly NuGet of December 13, 2022. 


NuGet Version: v20.3.0.61


We thank you for your support and appreciate your patience in waiting for this release. Please get in touch with us if you require any further assistance.


Loader.
Live Chat Icon For mobile
Up arrow icon