Forum Discussion

dheeraj10's avatar
dheeraj10
Microsoft Employee
7 years ago
Solved

Chiclet slicer shows only 1000 values

Hi,

Is there anyway to remove 1000 limit in Chiclet slicer for rows in vertical orientation?
Please help me on this.
  • dm-p's avatar
    dm-p
    7 years ago

    I think the issue would be that you're using a version of the tools that is too new for the visual. I suggest trying the following (I have tested these steps on my machine and they work for me):

    Cloning And Setup

    1. Clone the repository as normal.
    2. Run: npm i -g [email protected] (version number is important)
    3. You'll need to re-generate the certificate as the tooling has changed version. First run pbiviz --create-cert and then pbiviz --install-cert (it's two steps on the older tooling).
    4. Run npm i from the root folder of the project to make sure that the correct dependencies are installed (these are specified in package.json; using npm i to install packages manually will install the latest and not necessarily the correct ones for the code you're working with).

    Verification

    At this point, before making any changes, it's worth confirming that the code is in a ready state. The quickest way to do this is by using the development visual in the Power BI Surface as per the tutorial instructions. You can skip this section if you just want to compile the visual but it will be harder and more cumbersome to debug changes.

    1. Run pbiviz start from the project folder. This should compile as expected.
    2. Enable the developer visual as per the steps in the linked tutorial above.
    3. Add the Developer Visual to the canvas of your report.
    4. At this point, if the Developer Visual is blank (and not shaded grey with an error message) then the certificate is correctly allowing access to your code on your machine.
    5. Drag you desired field(s) into the visual and check it's doing what you expect.

    Modifying Source Code and Testing

    Now, you can make the changes you want. In your code, change the capabilities.json values, as well as the hard-coded settings previously linked from chicletSlicer.ts. When you save a file, the tooling should print the following in the console:

    When you've made all your changes, refresh the visual in the service to confirm they work. You do this by clicking the reload button on the visual toolbar, e.g.:

    Then, you should be able to make changes to the properties. For example, I changed my limit to 2000, so if I type 2001, the visual will cap it as follows:

    Packaging

    Once the code has been confirmed working, you can create the visual package:

    1. Change guid in pbiviz.json to a new value (adding 1 to the last number should be enough, as you were doing previously).
    2. Bonus points: it might also be worth changing the vales of name and displayName to indicate that this is your personalised Chiclet Slicer, so that if you have the marketplace version and your version loaded then you can confirm which is which by hovering over it, e.g.:

    3. Run pbiviz package from the root of your folder.
    4. Load the generated package into Desktop or the service as normal.

    This will make the changes you want. If you need specific help with concepts such as console.log (which is one of the most fundamental debugging tools you can use) then it will be worth investing some time in becoming familiar with JavaScript - there are quite a few sites that can help with this. Once you have JavaScript concepts, down, then learning TypeScript (which is what the majority of custom visuals are written in) is a fairly natural extension, and actually a bit nicer.

    Of course a good way to learn is to maybe have something like this visual working in the developer environment and them making changes and seeing what happens when you refresh the developer visual ;)

    Good luck,

    Daniel

9 Replies

  • dm-p's avatar
    dm-p
    Super User

    From reviewing the source code, the limit is set in the visual capabilities here and here (looks like it is capped for a couple of different configurations). The highest you can set this without specific coding work is 30,000.

    You could clone the repo, make these changes and compile your own version. Alternatively, the support link from the visual in AppSource advises the custom visuals ideas forum is the right place to ask for new features for visuals, so you may have better luck in there if you're looking for the team to pick this up for you.

    Good luck!

    Daniel

    • dheeraj10's avatar
      dheeraj10
      Microsoft Employee

      Thank you Daniel for your quick response.

       

      As you suggested, I have done the changes in respective places but to make it 2000 from 1000. Compiled the code using pbiviz to generate .pbiviz file and imported that file in power BI report. But the rows section seems to revert back to 1000 even if I enter 2000 or any number beyond 1000. Am I missing something here ?

       

      • dm-p's avatar
        dm-p
        Super User
        Hi,
        On mobile so don't have as much access to things (and nice formatting in posts!) but it looks like the limit is hard-coded for columns and rows here in the source code too: https://github.com/microsoft/PowerBI-visuals-ChicletSlicer/blob/5c3e679155dfa5ad49fbd19eab50cf043812839f/src/chicletSlicer.ts#L147
        One other thing: if you build your own version of a visual that's published to the marketplace, you need to change the guid property in pbiviz.json to be different. If it's the same as the published visual, it will always serve the one from the marketplace instead of the version from the compiled file. This is to ensure that reports always get the latest version of a published visual.
        I'm hoping this helps you get a bit further.
        Cheers,
        Daniel