# Using droptarget with dot syntax

**URL:** <https://forum.kirupa.com/t/using-droptarget-with-dot-syntax/52030>\
**Category:** flash\
**Created:** [May 19, 2004, 7:42am UTC](https://forum.kirupa.com/t/using-droptarget-with-dot-syntax/52030 "2004-05-19T07:42:39Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![El\_Bicho](https://avatars.discourse-cdn.com/v4/letter/e/dbc845/32.png) [@El\_Bicho](https://forum.kirupa.com/u/El_Bicho)\
**Post date:** [May 19, 2004, 7:42am UTC](https://forum.kirupa.com/t/using-droptarget-with-dot-syntax/52030/1 "2004-05-19T07:42:39Z")

</div>

How can I replace this code to use dot syntax instead of slash?

```auto

square.origX = _x;
square.origY = _y;

square.onPress = function() {
	this.startDrag();
};
square.onRelease = function() {
	stopDrag();
	if (square._droptarget != "/ball") {
		this._x = this.origX;
		this._y = this.origY;
	}
};

```

Thanks.
