Search Unity

  1. Get all the Unite Berlin 2018 news on the blog.
    Dismiss Notice
  2. Unity 2018.2 has arrived! Read about it here.
    Dismiss Notice
  3. Improve your Unity skills with a certified instructor in a private, interactive classroom. Learn more.
    Dismiss Notice
  4. ARCore is out of developer preview! Read about it here.
    Dismiss Notice
  5. Magic Leap’s Lumin SDK Technical Preview for Unity lets you get started creating content for Magic Leap One™. Find more information on our blog!
    Dismiss Notice
  6. Want to see the most recent patch releases? Take a peek at the patch release page.
    Dismiss Notice

TMProGUI InputField interactable scripting?

Discussion in 'Unity UI & TextMesh Pro' started by liquidbuddha, Jun 28, 2018.

  1. liquidbuddha

    liquidbuddha

    Joined:
    Jun 26, 2017
    Posts:
    3
    How do you change via script the Interactable toggle for a TextMeshProGUI input field, like you can with a standard input field.

    It does not seem to be a supported...
    [
    Error CS1061: 'TextMeshProUGUI' does not contain a definition for 'interactable' and no extension method 'interactable' accepting a first argument of type 'TextMeshProUGUI' could be found (are you missing a using directive or an assembly reference?) (CS1061) (Assembly-CSharp)
    ]
     
  2. FernandoHC

    FernandoHC

    Joined:
    Feb 6, 2018
    Posts:
    85
    hey liquid, you're supposed to change the object type TMP_Input.Interactable instead of the TextMeshProUGUI text inside it.
    edit. my bad, didn't see the standard there, but still interactable should be done on the input parent object instead of the children objects.
     
  3. liquidbuddha

    liquidbuddha

    Joined:
    Jun 26, 2017
    Posts:
    3
    ok thank you Fernando. I'll give that a try.