using UnityEngine;
using System.Collections;
using UnityEngine.UI;
public class Ctrl : MonoBehaviour {
public Text myText;
// Use this for initialization
void Start () {
myText = GetComponent<Text>();
myText.text = "myText...";
}
// Update is called once per frame
void Update () {
}
}
Im actually following the Tutorial from Unity lessons, but it don’t like me… I’m using
free version of 5.0.
What I am trying to do is get the Text component on the canvas and simply change the text on start dynamically as want to update it from a button event.