I would like to change the texture dynamically by using something like
GameObject loadedPrefab = Resources.Load("item") as GameObject;
loadedPrefab.transform.GetComponent<UITexture>().mainTexture="";
where item is a Texture widget prefab,
My image have been add to the atlas, or inside the Asset/Resources/image folder,
how can i set it to the mainTexture?