Skip to main content
Announcements
Qlik Connect 2024! Seize endless possibilities! LEARN MORE
cancel
Showing results for 
Search instead for 
Did you mean: 
Not applicable

QlikView - SVG Map of Iran needed

8 Replies
Michael_Tarallo
Employee
Employee

Hi Hossein, both QlikView Personal and Qlik Sense are free for download. I encourage you to take a look at Sense if you can. In QlikView - you need the map extension object available here:

http://market.qlik.com/qlikview-svg-map.html

Take a look at it and feel free to post questions to the QlikView Developer forums if you have questions about the QlikView SVG map.

Thanks

Mike

Regards,
Mike Tarallo
Qlik
Not applicable
Author

Hi Michael

I use SVG map it is exactly that I wanted! but there is not my country(IRAN) on svg map directory how can I find or create it?

Michael_Tarallo
Employee
Employee

Hi Hossein - let me see if I can help with this request.

Stand by

Mike

Regards,
Mike Tarallo
Qlik
Michael_Tarallo
Employee
Employee

Hi Hossein - here is what I have for you using QlikView.

8-11-2014 5-21-56 PM.jpg

I was able to get a SVG copy of Iran and edit the IDs of each province numbered 1 to 28.

I attached the .SVG file, sample data and .qvw file in this document  - you need to copy it to:

C:\Users\<user>\AppData\Local\QlikTech\QlikView\Extensions\Objects\svgMap

In QlikView Turn on WebView (I assume you have the SVG map installed)

8-11-2014 5-24-43 PM.jpg

Now with your data - you will need to update the .svg file (it is nothing more than XML) - and rename the values in the ID of the PATH to the corresponding data value in your data.

So for example:

<path id="1" class="path-city path-city-g1"  d="M82.7,37.8C82.2,37.8,81.5,38,80.4,38.3C76.9,39.2,76.1,39.8,74.6,42.7C73.4,45.1,75.5,46.5,73.7,48.9C72,51.1,70.6,49.7,70.6,53.3C70.6,55.5,70.6,57.7,70.6,60C70.6,62.2,68.2,64.1,67,65.3C65.2,67.1,60.1,65.5,59,64.4C57.3,62.7,53.8,63.7,52.3,64C50.2,64.4,50.1,63.3,47,62.7C43.8,62.1,45.2,66.7,45.7,67.6C47,70.2,47.7,72.4,48.4,75.1C49.3,78.5,47,79.5,49.7,82.2C51.5,84,56,82.7,55,86.6C54.3,89.4,51.7,88.2,52.8,92.4C53.3,94.5,50.6,96.1,50.6,99.1C50.6,101.8,51.9,102.8,51.9,106.2C51.9,107.5,56.3,109.2,57.2,111.1C57.4,111.5,56.4,114.5,55.9,115.5C55.8,116.2,55.6,117,55.5,117.7C55.1,119.8,54.8,123.1,55.1,124.4C55.7,126.8,57.3,125.9,57.3,129.3C57.3,131.9,57.9,134.5,56,136.4C54.5,137.9,54.8,140.4,54.2,142.6C53.5,145.3,54.5,146.9,56.4,147.9C59.3,149.3,61.8,146.4,64.4,147.5C66.8,148.5,65.6,152.1,64.8,153.7C64.2,154.9,61.2,156,60.4,156.8C58.7,158.5,59.3,160.8,58.2,163C57.1,165.2,55.9,167.1,53.8,169.2C52.4,170.6,51.2,172.3,50.2,173.6C48.3,176.2,47.3,176.7,46.7,179.4C46.1,181.8,45.8,183.8,45.8,186.1C45.8,189.3,50.6,188.2,52.9,188.8C56.3,189.7,55.2,190.2,56.4,192.8C57.2,194.3,59.8,194.1,60.8,195.5C62.4,197.7,66,196.7,67.9,198.6C69.3,200,68.1,203.3,67,204.4C66.1,205.3,64.9,205.6,64.3,206.2C63.4,207.1,67.7,212.8,67.9,213.3C68.4,215.2,67.4,219.1,66.1,220.4C64,222.5,65.2,225.2,67.4,225.7C69.8,226.3,70.8,226.4,71.4,228.8C71.7,230,75.6,231.7,76.3,232.4C78.7,234.8,78.8,235.9,79.4,239.1C79.7,240.6,76.1,242.7,76.7,245.8C77.3,249,76.6,248.8,75.8,252C75,255.1,74.2,254.1,78,256C80.6,257.3,82.4,257.4,82.4,260.4C82.4,262.6,80.3,263.8,81.1,266.6C82,270.1,81.5,270.6,78.9,273.3C76.7,275.5,79.6,278.6,81.6,278.6C82.1,278.6,82.5,278.9,82.9,279C87.3,279,88.1,282.6,90.5,284.3C92.5,285.8,91.5,290,90.1,291.4C88.8,292.7,87,297.7,86.5,299.4C86.2,300.6,89.2,300.8,89.2,302.1C89.2,305.5,90.5,306.5,91.9,309.2C93.2,311.7,96.7,311,98.6,309.6C100.7,308,102.6,312.8,103.5,314C104.5,315.4,102.2,319.4,102.2,321.1C102.2,323,104.9,323.2,104.9,326.4C104.9,329.3,101.9,330,105.3,331.7C108,333.1,105,337.5,104.4,338.4C102.6,340.9,103.1,343.3,106.2,343.3C108.8,343.3,111.2,341.5,114.6,341.5C116.2,341.5,117.4,341.8,118.2,342.4C118.9,339.9,119.7,337.7,120.5,336C125,326.2,125.9,328.8,125.9,328.8C125.9,328.8,125.9,324.4,132.2,322.6C138.5,320.8,141.1,322.6,146.5,321.7C151.9,320.8,148.3,312.8,152.8,309.2C154.2,308.1,155.3,307.7,156.4,307.6C158.7,307.6,160.7,309.5,164.4,310.1C169.8,311,181.3,314.6,192.1,311.9C202.8,309.2,201,309.2,205.5,316.4C210,323.5,219.8,320.9,225.2,322.7C230.6,324.5,229.6,312,235.9,310.2C236.2,310.1,236.4,310.1,236.7,310C236.5,309.2,236.1,308.1,235.9,307.5C233.8,299.8,228.5,297.1,228.8,291.6C225,291,222.1,290.6,220.8,290.6C213.7,290.6,210.1,295.1,207.4,288.8C204.7,282.6,211.8,278.1,208.3,273.6C204.7,269.1,206.5,265.6,201.2,265.6C195.8,265.6,198.5,257.6,194,262C189.5,266.5,191.3,262.9,186,263.8C180.6,264.7,183.3,272.7,178,271.8C172.6,270.9,176.2,276.3,171.7,271.8C167.2,267.3,164.6,259.3,156.5,256.6C148.4,253.9,143.1,246.8,137.7,245C132.3,243.2,123.4,240.5,121.6,235.2C119.8,229.9,119.8,224.5,119.8,219.1C119.8,213.7,116.2,209.3,114.5,203.9C112.8,198.5,113.6,177.1,113.6,171.8C113.6,166.5,103.8,159.3,105.6,154.8C107.4,150.3,119,142.3,121.7,137.9C124.4,133.4,126.2,136.1,124.4,128.1C122.6,120.1,121.7,118.3,127.1,111.1C128,109.9,130.3,107.3,133.1,104.3C132.6,103.9,132.2,103.6,131.9,103.5C129.2,102.1,129.2,100.3,129.2,97.3C129.2,93.3,126.9,92.3,126.1,89.3C125.2,85.8,120.5,86.3,118.1,84.9C117.3,84.4,116.2,83.9,115.4,83.6C114.7,83,113.9,82.4,113.2,81.8C111.6,80.6,111.4,75.9,110.9,74.2C110.5,72.8,107.9,69.8,106.9,68.9C104.6,66.6,102.4,65.8,102.4,62.2C102.4,59.8,101.6,57.9,101.1,56C100.4,53.4,98.8,51.5,98,50.7C96.3,49,93.9,48.2,91.8,45.4C89.9,42.9,88.1,42.2,86,40.1C84.6,38.7,84.3,38,83.4,37.9C83,37.8,82.9,37.8,82.7,37.8ZM229.1,288.8C229,289,228.9,289.3,228.8,289.5C228.9,289.2,229,289,229.1,288.8Z" stroke-width="5.2631578947368425" stroke-opacity="1" transform="matrix(0.38,0,0,0.38,0,0)">

</path>

will become "AZARBAIJAN E"  - as in:

<path id="AZARBAIJAN E" class="path-city path-city-g1"  d="M82.7,37.8C82.2,37.8,81.5,38,80.4,38.3C76.9,39.2,76.1,39.8,74.6,42.7C73.4,45.1,75.5,46.5,73.7,48.9C72,51.1,70.6,49.7,70.6,53.3C70.6,55.5,70.6,57.7,70.6,60C70.6,62.2,68.2,64.1,67,65.3C65.2,67.1,60.1,65.5,59,64.4C57.3,62.7,53.8,63.7,52.3,64C50.2,64.4,50.1,63.3,47,62.7C43.8,62.1,45.2,66.7,45.7,67.6C47,70.2,47.7,72.4,48.4,75.1C49.3,78.5,47,79.5,49.7,82.2C51.5,84,56,82.7,55,86.6C54.3,89.4,51.7,88.2,52.8,92.4C53.3,94.5,50.6,96.1,50.6,99.1C50.6,101.8,51.9,102.8,51.9,106.2C51.9,107.5,56.3,109.2,57.2,111.1C57.4,111.5,56.4,114.5,55.9,115.5C55.8,116.2,55.6,117,55.5,117.7C55.1,119.8,54.8,123.1,55.1,124.4C55.7,126.8,57.3,125.9,57.3,129.3C57.3,131.9,57.9,134.5,56,136.4C54.5,137.9,54.8,140.4,54.2,142.6C53.5,145.3,54.5,146.9,56.4,147.9C59.3,149.3,61.8,146.4,64.4,147.5C66.8,148.5,65.6,152.1,64.8,153.7C64.2,154.9,61.2,156,60.4,156.8C58.7,158.5,59.3,160.8,58.2,163C57.1,165.2,55.9,167.1,53.8,169.2C52.4,170.6,51.2,172.3,50.2,173.6C48.3,176.2,47.3,176.7,46.7,179.4C46.1,181.8,45.8,183.8,45.8,186.1C45.8,189.3,50.6,188.2,52.9,188.8C56.3,189.7,55.2,190.2,56.4,192.8C57.2,194.3,59.8,194.1,60.8,195.5C62.4,197.7,66,196.7,67.9,198.6C69.3,200,68.1,203.3,67,204.4C66.1,205.3,64.9,205.6,64.3,206.2C63.4,207.1,67.7,212.8,67.9,213.3C68.4,215.2,67.4,219.1,66.1,220.4C64,222.5,65.2,225.2,67.4,225.7C69.8,226.3,70.8,226.4,71.4,228.8C71.7,230,75.6,231.7,76.3,232.4C78.7,234.8,78.8,235.9,79.4,239.1C79.7,240.6,76.1,242.7,76.7,245.8C77.3,249,76.6,248.8,75.8,252C75,255.1,74.2,254.1,78,256C80.6,257.3,82.4,257.4,82.4,260.4C82.4,262.6,80.3,263.8,81.1,266.6C82,270.1,81.5,270.6,78.9,273.3C76.7,275.5,79.6,278.6,81.6,278.6C82.1,278.6,82.5,278.9,82.9,279C87.3,279,88.1,282.6,90.5,284.3C92.5,285.8,91.5,290,90.1,291.4C88.8,292.7,87,297.7,86.5,299.4C86.2,300.6,89.2,300.8,89.2,302.1C89.2,305.5,90.5,306.5,91.9,309.2C93.2,311.7,96.7,311,98.6,309.6C100.7,308,102.6,312.8,103.5,314C104.5,315.4,102.2,319.4,102.2,321.1C102.2,323,104.9,323.2,104.9,326.4C104.9,329.3,101.9,330,105.3,331.7C108,333.1,105,337.5,104.4,338.4C102.6,340.9,103.1,343.3,106.2,343.3C108.8,343.3,111.2,341.5,114.6,341.5C116.2,341.5,117.4,341.8,118.2,342.4C118.9,339.9,119.7,337.7,120.5,336C125,326.2,125.9,328.8,125.9,328.8C125.9,328.8,125.9,324.4,132.2,322.6C138.5,320.8,141.1,322.6,146.5,321.7C151.9,320.8,148.3,312.8,152.8,309.2C154.2,308.1,155.3,307.7,156.4,307.6C158.7,307.6,160.7,309.5,164.4,310.1C169.8,311,181.3,314.6,192.1,311.9C202.8,309.2,201,309.2,205.5,316.4C210,323.5,219.8,320.9,225.2,322.7C230.6,324.5,229.6,312,235.9,310.2C236.2,310.1,236.4,310.1,236.7,310C236.5,309.2,236.1,308.1,235.9,307.5C233.8,299.8,228.5,297.1,228.8,291.6C225,291,222.1,290.6,220.8,290.6C213.7,290.6,210.1,295.1,207.4,288.8C204.7,282.6,211.8,278.1,208.3,273.6C204.7,269.1,206.5,265.6,201.2,265.6C195.8,265.6,198.5,257.6,194,262C189.5,266.5,191.3,262.9,186,263.8C180.6,264.7,183.3,272.7,178,271.8C172.6,270.9,176.2,276.3,171.7,271.8C167.2,267.3,164.6,259.3,156.5,256.6C148.4,253.9,143.1,246.8,137.7,245C132.3,243.2,123.4,240.5,121.6,235.2C119.8,229.9,119.8,224.5,119.8,219.1C119.8,213.7,116.2,209.3,114.5,203.9C112.8,198.5,113.6,177.1,113.6,171.8C113.6,166.5,103.8,159.3,105.6,154.8C107.4,150.3,119,142.3,121.7,137.9C124.4,133.4,126.2,136.1,124.4,128.1C122.6,120.1,121.7,118.3,127.1,111.1C128,109.9,130.3,107.3,133.1,104.3C132.6,103.9,132.2,103.6,131.9,103.5C129.2,102.1,129.2,100.3,129.2,97.3C129.2,93.3,126.9,92.3,126.1,89.3C125.2,85.8,120.5,86.3,118.1,84.9C117.3,84.4,116.2,83.9,115.4,83.6C114.7,83,113.9,82.4,113.2,81.8C111.6,80.6,111.4,75.9,110.9,74.2C110.5,72.8,107.9,69.8,106.9,68.9C104.6,66.6,102.4,65.8,102.4,62.2C102.4,59.8,101.6,57.9,101.1,56C100.4,53.4,98.8,51.5,98,50.7C96.3,49,93.9,48.2,91.8,45.4C89.9,42.9,88.1,42.2,86,40.1C84.6,38.7,84.3,38,83.4,37.9C83,37.8,82.9,37.8,82.7,37.8ZM229.1,288.8C229,289,228.9,289.3,228.8,289.5C228.9,289.2,229,289,229.1,288.8Z" stroke-width="5.2631578947368425" stroke-opacity="1" transform="matrix(0.38,0,0,0.38,0,0)">

</path>

providing your data value is "AZARBAIJAN E"

Hope this helps.

Mike T

Qlik

Regards,
Mike Tarallo
Qlik
Not applicable
Author

ِDear Michael

It works nicely but the map you attached is old and some provinces are changed

I search the new svg file but when I change path ID with 1 or province name through the new svg file it doesn't work appropriately

I attach the svg file can you see it and help me to use this svg file instead of

thanks very much

Michael_Tarallo
Employee
Employee

Hello Hossein - using inkscape (Draw Freely. | Inkscape) and a text editor - I was able to visually view the SVG file. This type of file cannot be used, because the provinces are not polygonal shapes. Further inspection shows that the provinces are broken up by lines in the middle with an overall border around them. The path IDs need to be complete polygons - in order to fill them correctly.

8-12-2014 6-45-55 AM.jpg

Perhaps you can use inkscape to edit the one I sent you. It would take some work though.

Also maybe post a note in the QlikView Forums asking if someone knows of an updated SVG map for Iran, it could not hurt to try.

Stay well

Mike

Regards,
Mike Tarallo
Qlik
Not applicable
Author

Dear Michael

I want to add another filed in measure that if for example sales was selected then measure= sales else value or another another fileds

(I want to have 3 fields) that if select each of them change the measure of svg extension)

I use this command in measure box but it doesn't work properly

=If(GetSelectedCount(value)>=1,sales)

Not applicable
Author

Hi Michael

I solve my problem by correcting the command and set it to color Expression too so by selecting each of them the color is changed

I write in mesure :

=If(GetSelectedCount(cost)>=1,cost,

If(GetSelectedCount(sales)>=1,sales,

value

))

in color expression:

=If(GetSelectedCount(cost)>=1,'blue',

If(GetSelectedCount(sales)>=1,'purple',

'green'

))

and it works properly