Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
Hi,
I have a Google Maps for Marker clustering. How can I set the zoom size of the map. Because every time I used to scroll the mouse to see the markers. Please can anyone suggest me. I changed in the script.js file but it seems there is no changes affecting in the map.
Thanks.
Can anyone help me please
Hi Amelia
I use a variable
=max(aggr(if(max( round(256*pow(2,(_zoom_level -1)))+([longitude > 0]*((256*pow(2,_zoom_level ))/360)) )-min( round(256*pow(2,(_zoom_level -1)))+([longitude > 0] *((256*pow(2,_zoom_level ))/360)) ) <map_size_x AND max((256*pow(2,(_zoom_level-1)))+((0.5*log((1+(sin(([latitude > 0])*pi()/180)))/(1-(sin(([latitude > 0])*pi()/180)))))*((-256*pow(2,_zoom_level))/(2*pi()))))-min((256*pow(2,(_zoom_level-1)))+((0.5*log((1+(sin(([latitude > 0])*pi()/180)))/(1-(sin(([latitude > 0])*pi()/180)))))*((-256*pow(2,_zoom_level))/(2*pi()))))<map_size_y,_zoom_level,1),_zoom_level))'
Where Latitude >0 and Longitude >0 are our database fields
Not sure if this helps but it works for our documents.
Thanks. Where I need to create this variable in qvw? could please let me know.
In the script editor with the code that defines your map variables
So....
What happens if the variable, for whatever reason, gets lost?
Which can happen from time to time.
Make it a rule without exceptions to:
- Never declare variables in the variable editor.
- Always declare variables in the script editor.
I personally have never had an issue with varible getting lost, and have variables that have been declared in both variable and script editor but for ones that will not change such as the above the script editor makes more sense.
The extension will automatically zoom to fit the available markers.
If you don't want that behavior you would have to edit the script.js file and set your own zoomlevel and centers and remove the latlngbounds logic.
Thanks very much. I tried to change the script but there is no change in the zoom level. moreover when I am refreshing it is showing an error which is in attached. Please could help me a this is very urgent for me priority task. I have tried in many ways but no luck for me. Please suggest me.
Please could help me to know why it is showing that error.