# Object move inside the vision template by property

**URL:** <https://forum.inductiveautomation.com/t/object-move-inside-the-vision-template-by-property/44915>\
**Category:** Ignition\
**Tags:** vision\
**Created:** [March 25, 2021, 3:34pm UTC](https://forum.inductiveautomation.com/t/object-move-inside-the-vision-template-by-property/44915 "2021-03-25T15:34:22Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![stra](https://sea1.discourse-cdn.com/inductiveautomation/user_avatar/forum.inductiveautomation.com/stra/32/23678_2.png) [@stra](https://forum.inductiveautomation.com/u/stra)\
**Post date:** [March 25, 2021, 3:34pm UTC](https://forum.inductiveautomation.com/t/object-move-inside-the-vision-template-by-property/44915/1 "2021-03-25T15:34:22Z")

</div>

I’m looking for a method to move an object within a template based on a property of the template itself. (i read this: [Moving Template inside window based on tag value in Ignition 8 - Ignition - Inductive Automation Forum](http://forum.inductiveautomation.com/t/moving-template-inside-window-based-on-tag-value-in-ignition-8/28037))  
I figured out how to move objects with system.gui.transform but I didn’t understand when to trigger the script.  
I try in a property change event but is fired only when the property is really change in runtime! how to do first time? is not clear for me  
is possible

```auto
if event.propertyName == 'ROT':
	if event.newValue == 0:
		xPos = 7
		yPos = 18
	elif event.newValue == 90:
		xPos = 15
		yPos = 48
	elif event.newValue == 180:
		xPos = 7
		yPos = 34
	else :
		xPos = 0
		yPos = 48

	system.gui.transform(component=event.source.getComponent('Label_MID'), newX=xPos, newY=yPos)

```
