Geo CHart and colorAxis – how to use?

Forums SPJS Charts for SharePoint Geo CHart and colorAxis – how to use?

This topic contains 3 replies, has 2 voices, and was last updated by  Alexander Bautz 8 months ago.

  • Author
    Posts
  • #16334

    Jon Whisman
    Participant

    Hi – I’m using v4.14 to evaluate the chart functionality and am playing with the Geo Charts to render to US states map (resolution = provinces) that is connected to a simple list with 2 columns: “State” and “Contact” (name of person to contact for that state).

    Currently, the states with data (only 3 states so far for my testing), have the background color of green, but I’d like to either assign each state a specific background color, or have random colors like what the colorAxis provides.

    I’m having difficulty setting up the colorAxis. What I have is attached, should I do something else to color code my states, or is my syntax for colorAxis wrong here?

    • This topic was modified 8 months ago by  Jon Whisman.
  • #16346

    Alexander Bautz
    Keymaster

    Hi,
    I haven’t tested this, but the format should be like this:

    {"colors":["blue","gray","red"]}

    Let me know how this works out.

    Alexander

  • #16348

    Jon Whisman
    Participant

    Thanks for the quick reply – no change. Still shows the same when using {“colors”:[“blue”,”gray”,”red”]}

  • #16350

    Alexander Bautz
    Keymaster

    I did a test here with v6 of the chart solution and got it working – see attached images.

    You should update to the latest version of SPJS Charts as I’m not 100% sure this will work in v4 – let me know if you need a trial license.

    PS: The state name is in the “Title” column in the data source list.

    Alexander

You must be logged in to reply to this topic.