1
0

Delete article

Deleted articles cannot be recovered.

Draft of this article would be also deleted.

Are you sure you want to delete this article?

More than 1 year has passed since last update.

UnityのInputFieldのtextを取得する方法

Last updated at Posted at 2019-05-09

UnityのInputFieldのtextを取得する方法

onValueChangedや、onEndEditに関する情報が多く見られますが、次のように単純に取得することができます。

GameObject inputField = GameObject.Find("InputField");
InputField input = inputField.GetComponent<InputField>();
Debug.Log(input.text); //textが出力される

終わりに

私は現在、Web3のサービスの開発をしています。詳しくはこちらの記事をご覧下さい。
無料でイーサリアムが当たる、Web3時代の寄付サイトを作った話
ありがとうございました。

1
0
0

Register as a new user and use Qiita more conveniently

  1. You get articles that match your needs
  2. You can efficiently read back useful information
  3. You can use dark theme
What you can do with signing up
1
0

Delete article

Deleted articles cannot be recovered.

Draft of this article would be also deleted.

Are you sure you want to delete this article?