# Controlling WordMap node - "Auto-pan" command

**URL:** https://discourse.nodered.org/t/controlling-wordmap-node-auto-pan-command/46611
**Category:** Dashboard
**Created:** [2 June 2021 17:08 UTC](https://discourse.nodered.org/t/controlling-wordmap-node-auto-pan-command/46611 "2021-06-02T17:08:35Z")
**Posts on this page:** 7
**Page:** 1

<div class="post-metadata">

### Author: ![NPT](https://avatars.discourse-cdn.com/v4/letter/n/9de053/32.png) [@NPT](https://discourse.nodered.org/u/NPT)
#### Post date: [2 June 2021 17:08 UTC](https://discourse.nodered.org/t/controlling-wordmap-node-auto-pan-command/46611/1 "2021-06-02T17:08:35Z")

</div>

I am successfully sending commands to the WorldMap node but have not found a command for setting Auto-pan on/off other than manually. Looking on the list of commands there doesn't appear to be a command available.

I am hoping to be able to drag the displayed map away from the position centred on the GPS location, so I can 'look ahead' at other adjacent areas. I could then toggle between free dragging and displaying the position.

Any thoughts of suggestions would be greatly appreciated!

---

<div class="post-metadata">

### Author: ![dceejay](https://sea2.discourse-cdn.com/flex026/user_avatar/discourse.nodered.org/dceejay/32/38_2.png) [@dceejay](https://discourse.nodered.org/u/dceejay)
#### Post date: [3 June 2021 21:05 UTC](https://discourse.nodered.org/t/controlling-wordmap-node-auto-pan-command/46611/2 "2021-06-03T21:05:31Z")

</div>

Hi,

hmm - I think you can use a map command { panit : true } to turn it on and false for off..  
not sure why it isn't documented - but let me know if it works and I'll fix it either way.

---

<div class="post-metadata">

### Author: ![NPT](https://avatars.discourse-cdn.com/v4/letter/n/9de053/32.png) [@NPT](https://discourse.nodered.org/u/NPT)
#### Post date: [3 June 2021 21:41 UTC](https://discourse.nodered.org/t/controlling-wordmap-node-auto-pan-command/46611/3 "2021-06-03T21:41:29Z")

</div>

HI,

Thanks for getting back to me!

I've just tried the commands. Unfortunately both **{"panit" : true }** and **{"panit" : false }** have the same effect - they certainly disable the Auto Pan set in the node settings! We are getting there!

---

<div class="post-metadata">

### Author: ![dceejay](https://sea2.discourse-cdn.com/flex026/user_avatar/discourse.nodered.org/dceejay/32/38_2.png) [@dceejay](https://discourse.nodered.org/u/dceejay)
#### Post date: [4 June 2021 09:38 UTC](https://discourse.nodered.org/t/controlling-wordmap-node-auto-pan-command/46611/4 "2021-06-04T09:38:12Z")

</div>

Ok - small fix pushed - true should now enable - v2.15.1  
(you can of course just recentre the map to wherever with a command also so that could be a work around also.)

---

<div class="post-metadata">

### Author: ![NPT](https://avatars.discourse-cdn.com/v4/letter/n/9de053/32.png) [@NPT](https://discourse.nodered.org/u/NPT)
#### Post date: [4 June 2021 13:55 UTC](https://discourse.nodered.org/t/controlling-wordmap-node-auto-pan-command/46611/5 "2021-06-04T13:55:37Z")

</div>

Hi,

I've upgraded and restarted but no change for me, I'm afraid. Once _panit_ is unset, it remains so. I am monitoring the messages sent for each condition via debug and the correct command object values are shown. Interestingly _panlock_ does work - both set and unset!

**WORKING TOGGLES:**

**PANLOCK**  
{"command":{"panlock":"true"}}; Working!  
{"command":{"panlock": "false"}}; Working!

Switches between modes – “locked” or “unlocked”

**NON WORKING TOGGLES:**

**COORDS**  
{"command":{"coords":"deg"}}; Working - turns decimal degree coordinates on  
{"command":{"coords": "none"}}; Not working – makes no change, coordinates remain visible

Turns co-ordinates on only. Cannot turn off.

**PAN**  
{"command":{"panit":true}} Working – switches map to draggable mode  
{"command":{"panit":false}} Not working - does nothing

Switches Auto Pan off but will not switch back on again.

These are the only three commands I have tried so far.

Your kind guidance for using this excellent node is greatly appreciated !

---

<div class="post-metadata">

### Author: ![NPT](https://avatars.discourse-cdn.com/v4/letter/n/9de053/32.png) [@NPT](https://discourse.nodered.org/u/NPT)
#### Post date: [7 June 2021 15:35 UTC](https://discourse.nodered.org/t/controlling-wordmap-node-auto-pan-command/46611/6 "2021-06-07T15:35:59Z")

</div>

Many thanks for v2.15.2 - it certainly addresses the issue of AutoPan on/off!

Brilliant!.

---

<div class="post-metadata">

### Author: ![system](https://us1.discourse-cdn.com/flex026/uploads/nodered/original/1X/d073cd938eafa2e558d7c2cd59003b3ef4963033.png) [@system](https://discourse.nodered.org/u/system)
#### Post date: [7 July 2021 15:36 UTC](https://discourse.nodered.org/t/controlling-wordmap-node-auto-pan-command/46611/7 "2021-07-07T15:36:07Z")

</div>

This topic was automatically closed 30 days after the last reply. New replies are no longer allowed.
