unity position ui element

C#
// To get or set the position of a UI element, see below:
GameObject.GetComponent<RectTransform>().anchoredPosition;
Source

Also in C#: