Search Issue Tracker
Fixed in 2018.3.X
Votes
0
Found in
2017.4.4f1
Issue ID
1040277
Regression
No
[UI] InputFiled Character Limit causes ArgumentOutOfRange exception while selecting text in Inspector
How to reproduce:
1. Create UI -> InputField
2. Select InputField in Hierarchy and Change Content Type to Standart, Name, etc... in Inspector Window
3. Change Character Limit to 9
4. Enter Play Mode
5. Write any text into InputField in Game Window
6. While in Play Mode, Select InputField in Hierarchy
7. Under Text field, select whole written text and write anything else
Actual result: ArgumentOutOfRangeException: Argument is out of range.
Parameter name: index
System.Collections.Generic.List`1[UnityEngine.UICharInfo].get_Item (Int32 index) (at /Users/builduser/buildslave/mono/build/mcs/class/corlib/System.Collections.Generic/Dictionary.cs:225)
UnityEngine.UI.InputField.SetDrawRangeToContainCaretPosition (Int32 caretPos) (at C:/buildslave/unity/build/Extensions/guisystem/UnityEngine.UI/UI/Core/InputField.cs:1826)
UnityEngine.UI.InputField.UpdateLabel () (at C:/buildslave/unity/build/Extensions/guisystem/UnityEngine.UI/UI/Core/InputField.cs:1694)
UnityEngine.UI.InputField.OnValidate () (at C:/buildslave/unity/build/Extensions/guisystem/UnityEngine.UI/UI/Core/InputField.cs:547)
UnityEngine.GUIUtility:ProcessEvent(Int32, IntPtr)
Reproduced with: 2017.1.4f1, 2017.2.3f1, 2017.4.4f1, 2018.1.2f1, 2018.2.0b5
Comments (2)
Add comment
All about bugs
View bugs we have successfully reproduced, and vote for the bugs you want to see fixed most urgently.
Latest issues
- EditorGUILayout.PropertyField foldout icon inside Vertical Layout Group has an incorrect indent when used with OnInspectorGUI()
- [Android] [iOS] "NullReferenceException: Object reference not set to an instance of an object" throws when entering the Play Mode/opening the application
- The Player freezes on load when building Web platform
- Animator "Conditions" tab breaks when the only Parameter is deleted and another one is created
- "Shader error in 'Universal Render Pipeline/Lit': maximum ps_5_0 sampler register index (16) exceeded" error thrown after a build is completed when the "LOD Cross Fade" parameter is enabled
michaeleconomy
Sep 19, 2020 20:29
I'm getting this on 2019.4.10f1
Eldirfar
Apr 08, 2019 18:07
Fix for LTS?