Skip to main content
cancel
Showing results for 
Search instead for 
Did you mean: 
crystles
Partner - Creator III
Partner - Creator III

SVG Map changes slowly?

I am using the SVG map extension and have a full United States map object on the main page. Then, when you select a state on the map, a button appears to show you the map of the individual state.

At first, I created an object for each state (50 svg objects) plus the one for the US.

Then I figured out you could put a formula in the box for the SVG file and I put a formula there instead that compares the selected state, to the SVG file on the server. However, when I click the button to show the state, it takes it one second longer to change the image from the last state selected to the current state selected. Is there a way to speed up this process? Or possibly slow down the changing of the maps? (each map object has a "Show Condition" so the US map disappears and the States map reappears)

Here is my formula for the states map, and it goes here in the Properties window on the SVG map object

[Properties -> SVG Map -> Load SVG path] .

=
IF( GetFieldSelections(STATE_REGISTRATION)='AL', 'Alabama_Counties.svg',
IF( GetFieldSelections(STATE_REGISTRATION)='AK', 'Alaska_Counties.svg',
IF( GetFieldSelections(STATE_REGISTRATION)='AZ', 'Arizona_Counties.svg',
IF( GetFieldSelections(STATE_REGISTRATION)='AR', 'Arkansas_Counties.svg',
IF( GetFieldSelections(STATE_REGISTRATION)='CA', 'California_Counties.svg',
IF( GetFieldSelections(STATE_REGISTRATION)='CO', 'Colorado_Counties.svg',
IF( GetFieldSelections(STATE_REGISTRATION)='CT', 'Connecticut_Counties.svg',
IF( GetFieldSelections(STATE_REGISTRATION)='DE', 'Delaware_Counties.svg',
IF( GetFieldSelections(STATE_REGISTRATION)='FL', 'Florida_Counties.svg',
IF( GetFieldSelections(STATE_REGISTRATION)='GA', 'Georgia_Counties.svg',
IF( GetFieldSelections(STATE_REGISTRATION)='HI', 'Hawaii_Counties.svg',
IF( GetFieldSelections(STATE_REGISTRATION)='ID', 'Idaho_Counties.svg',
IF( GetFieldSelections(STATE_REGISTRATION)='IL', 'Illinois_Counties.svg',
IF( GetFieldSelections(STATE_REGISTRATION)='IN', 'Indiana_Counties.svg',
IF( GetFieldSelections(STATE_REGISTRATION)='IA', 'Iowa_Counties.svg',
IF( GetFieldSelections(STATE_REGISTRATION)='KS', 'Kansas_Counties.svg',
IF( GetFieldSelections(STATE_REGISTRATION)='KY', 'Kentucky_Counties.svg',
IF( GetFieldSelections(STATE_REGISTRATION)='LA', 'Louisiana_Counties.svg',
IF( GetFieldSelections(STATE_REGISTRATION)='ME', 'Maine_Counties.svg',
IF( GetFieldSelections(STATE_REGISTRATION)='MD', 'Maryland_Counties.svg',
IF( GetFieldSelections(STATE_REGISTRATION)='MA', 'Massachusetts_Counties.svg',
IF( GetFieldSelections(STATE_REGISTRATION)='MI', 'Michigan_Counties.svg',
IF( GetFieldSelections(STATE_REGISTRATION)='MN', 'Minnesota_Counties.svg',
IF( GetFieldSelections(STATE_REGISTRATION)='MS', 'Mississippi_Counties.svg',
IF( GetFieldSelections(STATE_REGISTRATION)='MO', 'Missouri_Counties.svg',
IF( GetFieldSelections(STATE_REGISTRATION)='MT', 'Montana_Counties.svg',
IF( GetFieldSelections(STATE_REGISTRATION)='NE', 'Nebraska_Counties.svg',
IF( GetFieldSelections(STATE_REGISTRATION)='NV', 'Nevada_Counties.svg',
IF( GetFieldSelections(STATE_REGISTRATION)='NH', 'NewHampshire_Counties.svg',
IF( GetFieldSelections(STATE_REGISTRATION)='NJ', 'New_Jersey_Counties.svg',
IF( GetFieldSelections(STATE_REGISTRATION)='NM', 'NewMexico_Counties.svg',
IF( GetFieldSelections(STATE_REGISTRATION)='NY', 'NewYork_Counties.svg',
IF( GetFieldSelections(STATE_REGISTRATION)='NC', 'NorthCarolina_Counties.svg',
IF( GetFieldSelections(STATE_REGISTRATION)='ND', 'NorthDakota_Counties.svg',
IF( GetFieldSelections(STATE_REGISTRATION)='OH', 'Ohio_Counties.svg',
IF( GetFieldSelections(STATE_REGISTRATION)='OK', 'Oklahoma_Counties.svg',
IF( GetFieldSelections(STATE_REGISTRATION)='OR', 'Oregon_Counties.svg',
IF( GetFieldSelections(STATE_REGISTRATION)='PA', 'Pennsylvania_Counties.svg',
IF( GetFieldSelections(STATE_REGISTRATION)='RI', 'RhodeIsland_Counties.svg',
IF( GetFieldSelections(STATE_REGISTRATION)='SC', 'SouthCarolina_Counties.svg',
IF( GetFieldSelections(STATE_REGISTRATION)='SD', 'SouthDakota_Counties.svg',
IF( GetFieldSelections(STATE_REGISTRATION)='TN', 'Tennessee_Counties.svg',
IF( GetFieldSelections(STATE_REGISTRATION)='TX', 'Texas_Counties.svg',
IF( GetFieldSelections(STATE_REGISTRATION)='UT', 'Utah_Counties.svg',
IF( GetFieldSelections(STATE_REGISTRATION)='VT', 'Vermont_Counties.svg',
IF( GetFieldSelections(STATE_REGISTRATION)='VA', 'Virginia_Counties.svg',
IF( GetFieldSelections(STATE_REGISTRATION)='WA', 'Washington_Counties.svg',
IF( GetFieldSelections(STATE_REGISTRATION)='WV', 'WestVirginia_Counties.svg',
IF( GetFieldSelections(STATE_REGISTRATION)='WI', 'Wisconsin_Counties.svg',
IF( GetFieldSelections(STATE_REGISTRATION)='WY', 'Wyoming_Counties.svg')
)))))))))))))))))))))))))))))))))))))))))))))))))


1 Reply
sunny_talwar

May be use Pick(Match(...)) instead....

Pick(Match(GetFieldSelections(STATE_REGISTRATION), 'AL', 'AK'......'WY'), 'Alabama_Counties.svg', 'Alaska_Counties.svg',...... 'Wyoming_Counties.svg')