locked
Displaying a filled polygon with Excel Add-in RRS feed

  • Question

  • Hi there, I'm having quite a bit of success displaying WKT polygons, using the Excel Add-in, but I don't seem to have any control over the thickness of the line that shows the polygon outline, and I can't see a way to represent the polygon as filled, rather than just an outline. Does anyone know how to do this?

    And also, how do you do Hover text on a polygon? It just works fine with points, but I can't seem to get Hover Text to display with polygons.

    If you fancy giving it a go, here's a model dataset, to save you having to create one

    Name Geometry
    UKSquare POLYGON ((0 51, 0 52, -1 52, -1 51, 0 51))

    Cheers

    Sam


    • Edited by Sam Loud Thursday, October 11, 2012 12:12 PM
    Thursday, October 11, 2012 12:11 PM

Answers

  • Thanks for your input guys. The answer was really pretty simple. polygons have to be represented with their points in a clockwise order. My example above was anticlockwise, and WWT renders that as an unfilled line. If you reorder the points so they run clockwide, it shows it as a filled polygon.

    Name Geometry Color
    Anticlockwise (bad) POLYGON ((0 51, 0 52, -1 52, -1 51)) Red
    Clockwise (good) POLYGON((0 52, -1 52, -1 53, 0 53)) Blue
    Clockwise (good) POLYGON((-2 51, -3 51, -3 52, -2 52)) Yellow

    Worth bearing in mind.

    Cheers

    Sam

    Friday, November 2, 2012 1:35 PM

All replies

  • Hi Sam,

    I do not exactly how to change the line thickness but you can do rest of the things using excel add-in. Excel Add-in comes with four samples and there are 2 samples on geometry based data.

    The polygons example can be seen in Earth based geometery data. After selecting the data which you want to send to WWT you can provide your settings in the Marker tab as shown in the below screen shot.

    Another way of achievingb the same is to rightClick the layer you sent from the WWT and set the options as shown below.

    Let me know if this helps you.

    -Regards

    • Proposed as answer by Kalnemi Wednesday, October 31, 2012 10:54 AM
    Wednesday, October 31, 2012 10:54 AM
  • Wednesday, October 31, 2012 11:26 AM
  • Thanks for your input guys. The answer was really pretty simple. polygons have to be represented with their points in a clockwise order. My example above was anticlockwise, and WWT renders that as an unfilled line. If you reorder the points so they run clockwide, it shows it as a filled polygon.

    Name Geometry Color
    Anticlockwise (bad) POLYGON ((0 51, 0 52, -1 52, -1 51)) Red
    Clockwise (good) POLYGON((0 52, -1 52, -1 53, 0 53)) Blue
    Clockwise (good) POLYGON((-2 51, -3 51, -3 52, -2 52)) Yellow

    Worth bearing in mind.

    Cheers

    Sam

    Friday, November 2, 2012 1:35 PM