Search Unity

UI not showing when I right click on hierarchy!

Discussion in 'UGUI & TextMesh Pro' started by Boy2000, Aug 23, 2019.

  1. Boy2000

    Boy2000

    Joined:
    Aug 21, 2019
    Posts:
    8
    I'm using Unity Version 2019.2.0f1, When I right-click in the hierarchy, UI option doesn't show up, please tell me how to fix it, is there some files that I'm missing? If that's the case please let me know how to fix it.
     
    adhochero likes this.
  2. uDamian

    uDamian

    Unity Technologies

    Joined:
    Dec 11, 2017
    Posts:
    1,231
    You mean, if you right-click in the Hierarchy window, no right-click menu shows up? Like, right-click does nothing in the Hierachy window?
     
  3. adhochero

    adhochero

    Joined:
    Feb 2, 2017
    Posts:
    43
    I am having the same issue. But when I right click in the hierarchy window, the pop up window to create new empty, 3d objects, etc, it opens but the UI option is not there
     
    Little_Robot_Guys likes this.
  4. adhochero

    adhochero

    Joined:
    Feb 2, 2017
    Posts:
    43
    D5B8A8C2-D57F-47DA-BAD0-2AC71EF50E74.jpeg
     
    AngoGames and Shoukrollah like this.
  5. adhochero

    adhochero

    Joined:
    Feb 2, 2017
    Posts:
    43
    Sorry for so many replys but im on mobile and the edit is impossible. It s okay now just saved and restart unity and the UI option is back
     
    amardari and Shoukrollah like this.
  6. Boy2000

    Boy2000

    Joined:
    Aug 21, 2019
    Posts:
    8
    Restarting Unity doesn’t help me though! It’s still the same!
     
    DaffaAstrid likes this.
  7. uDamian

    uDamian

    Unity Technologies

    Joined:
    Dec 11, 2017
    Posts:
    1,231
    Oh, I understand now. This is a uGUI question (there's a different forum for uGUI as its a different framework than UIElements - I'll move the thread).

    In any case, uGUI is a package now so it's possible that if the uGUI package was now properly compiled you won't get the UI option in that menu. Check the Console for errors.

    Moving thread to: https://forum.unity.com/forums/unity-ui-ugui-textmesh-pro.60/
     
  8. l8njacobs

    l8njacobs

    Joined:
    Dec 12, 2016
    Posts:
    5
    Has anyone found a fix to this issue? I'm running Unity 2019.1.7f1 and have been having this problem in specific projects.

    I've deleted the Library folder and restarted Unity, it still hasn't fixed the issue.
     
  9. InitusInteractive

    InitusInteractive

    Joined:
    Aug 16, 2018
    Posts:
    128
    I'm having this same issue, no idea where it went..
     
  10. InitusInteractive

    InitusInteractive

    Joined:
    Aug 16, 2018
    Posts:
    128
    Fixed it, removed Unity UI and TextMeshPro, then readded them both, restarted and now UI is back in the Scene context menu.
     
  11. Cachorro_JooJ

    Cachorro_JooJ

    Joined:
    Jun 19, 2020
    Posts:
    1
    But how can i remove Unity UI and TextMeshPro?
     
    honor0102 likes this.
  12. RamyGHOST

    RamyGHOST

    Joined:
    May 8, 2020
    Posts:
    2
    go to window, package manager then search for text mesh pro and unity UI (you need to remove text mesh pro first)
     
    INL_AVL and ritikbheda like this.
  13. rjjderks

    rjjderks

    Joined:
    Jul 9, 2020
    Posts:
    1
    That does the trick! Thanks
     
  14. parthsovani

    parthsovani

    Joined:
    May 25, 2020
    Posts:
    1
    i cant seee unity ui in package manager
     
  15. Devster2020

    Devster2020

    Joined:
    Feb 12, 2018
    Posts:
    3
    You need to look at the top of the "Package Manager" window... there is a dropdown menu with "In Project" label.. click on it and select "All Packages".
    Now you can see the package you're looking for.
     
  16. Lapsapnow

    Lapsapnow

    Joined:
    Jul 4, 2019
    Posts:
    51
    Same problem,

    SOLUTION : Just try a good old restart. It fixed it for me.
     
  17. Petreus

    Petreus

    Joined:
    Feb 28, 2021
    Posts:
    1
    UNITY 2020.2.1f1
    still this bug accours, I think is time u guys do something about it, I did 2 progects, it accoured 2 times in a row in 2 weeks
     
    Little_Robot_Guys likes this.
  18. iam11yearsoldboiiiii

    iam11yearsoldboiiiii

    Joined:
    Mar 11, 2021
    Posts:
    7
    I tried every possible solution that i could fin on google and none of them worked.
    I have the same issue that everyone else here has. Someone please help.
    This is my 5th project failing so if anyone of you can help please, you'll be a life saver
     
    Little_Robot_Guys likes this.
  19. iam11yearsoldboiiiii

    iam11yearsoldboiiiii

    Joined:
    Mar 11, 2021
    Posts:
    7
    I HAVE THE S A M E PROBLEM I NEED YOUR HELP
     
    Little_Robot_Guys likes this.
  20. Topusku

    Topusku

    Joined:
    Mar 16, 2019
    Posts:
    1
    Using 2020.3.0f1 and this bug still occurs.

    I haven't found any solution that seems to work at the moment and it's pretty crucial to get TextMeshPro/UI elements working. It seems to be happening in every project, so there's probably a problem importing the assets or packages.

    Screenshot_317.png
     
    Last edited: Mar 22, 2021
    Little_Robot_Guys likes this.
  21. Little_Robot_Guys

    Little_Robot_Guys

    Joined:
    May 7, 2018
    Posts:
    6
    I also am getting this issue. Saving/restarting didn't help. Why is this not fixed yet?
    upload_2021-3-23_11-6-47.png

    Steps to reproduce:
    1.) Create a new scene, using EMPTY template.
    2.) Attempt to right-click in the Hierarchy to create any UI element of any kind (Canvas, Button, Text, Whatever)
    3.) Throw laptop out window.

    The only way to get things lined up easily in this state is to click the element in question, and go up to GameObject menu at the top, and for some reason UI menu is there (but at the very bottom, away from other "Create" options. See below:
    upload_2021-3-23_11-10-35.png
     
    asnupy likes this.
  22. Little_Robot_Guys

    Little_Robot_Guys

    Joined:
    May 7, 2018
    Posts:
    6
    Submitted a bug with a project file and link to this thread. Cross your fingers.
     
  23. leoteloken03

    leoteloken03

    Joined:
    Mar 26, 2021
    Posts:
    1
    I'm having this issue that you described, mine righ-click isn't working in the hierarchy window
     
    Shoukrollah likes this.
  24. FantasticGlass

    FantasticGlass

    Joined:
    May 31, 2016
    Posts:
    38
    Ya I'm having the same issue. 2020.3.1f1. Tried removing Unity UI and Text Mesh Pro packages, restarting windows and reinstalling.
    Nothing worked.
    Pls help. I can't create a new project!!! :(

    Also the Unity Collaborate Package has a corrupted .cs file. AdapterListView.cs.
    Only half a line of code is contained in the .cs file. removing, restarting, and installing the Unity Collaborate package has no effect on this error.
     
  25. FantasticGlass

    FantasticGlass

    Joined:
    May 31, 2016
    Posts:
    38
    SOLUTION:
    I just fixed it by removing each package one by one, with a full system restart in between each removal.
    And also a restart in between each installation of the packages again.

    Hope this will work for someone else!
     
  26. SuperLolGuy7865

    SuperLolGuy7865

    Joined:
    Apr 7, 2021
    Posts:
    1
    Click on GameObject on the top then see UI at the very bottom of the list imageUnityReply.PNG
     
    HadezBlue, DaFiTime and MaxAllen05 like this.
  27. MaxAllen05

    MaxAllen05

    Joined:
    Jul 26, 2020
    Posts:
    1
    Thank you so much that worked
     
  28. nightborn

    nightborn

    Joined:
    Jan 2, 2018
    Posts:
    4
    Why is that this has changed? I find this very unusable...
     
  29. fjshomeplate

    fjshomeplate

    Joined:
    Feb 3, 2019
    Posts:
    12
    Same problem with 2D primitives... in unity 2020.2.2f
     
  30. kfcbucketyay

    kfcbucketyay

    Joined:
    Jun 29, 2021
    Posts:
    1
    How do I Re add them?
     
  31. Dubitrubi

    Dubitrubi

    Joined:
    Jan 31, 2020
    Posts:
    5
    Reverting the Unity Hub version from the Beta 3.0 to Production 2.4.4 solved this problem for me.
     
  32. hieutt_unity65

    hieutt_unity65

    Joined:
    Jul 1, 2021
    Posts:
    3
    It worked.
    And I realize when I used hub 3.0, so many errors appears when open project, but that errors can clear.
     
  33. dohyun9565

    dohyun9565

    Joined:
    Oct 13, 2020
    Posts:
    1
    It's resolved.
     
  34. EmpireOfLight

    EmpireOfLight

    Joined:
    Aug 6, 2021
    Posts:
    4
    I have just encountered this same issue in Unity 2020.3.15f2. It was there just a few minutes ago and now it's disappeared. Restarting Unity itself fixed the problem. I did not alter installed packages in any way.
     
    tonialatalo likes this.
  35. Jolykj

    Jolykj

    Joined:
    Nov 9, 2018
    Posts:
    1
    Did you find a solution to this problem?
     
  36. enaielei

    enaielei

    Joined:
    Apr 8, 2021
    Posts:
    11
    Lol... Just realized that I'm having the same issue.
    I'm using Unity Hub 3.0.0.beta-4 and Unity Editor 2021.3.16f1.
    I guess I'll stick to the GameObject menu for now.
     
  37. rajeshkalavakunta

    rajeshkalavakunta

    Joined:
    Aug 20, 2021
    Posts:
    2
    I had the same problem, It will happen when packages are not resolved.
    - Restart the Unity, Packages are automatically resolved.
     
  38. humanMusic

    humanMusic

    Joined:
    May 16, 2017
    Posts:
    16
    If you still have issues, I solved it in a very brute force way. I downloaded a random UI asset from the asset store, imported it into my scene, made duplicates of the cavas and any gameobjects I needed and deleted the rest.
     
  39. erickgnwnt

    erickgnwnt

    Joined:
    Oct 28, 2021
    Posts:
    1
    u r so guud brahhhh
     
  40. HTMLJSCSS

    HTMLJSCSS

    Joined:
    Dec 21, 2018
    Posts:
    1
    Here's a fix:
    1. Click on Window > Package Manager
    2. Remove UnityUI and TextMeshPro
    3. Click on Packages: In Project
    4. Search for UnityUI and TextMeshPro and re-add them
    5. Restart unity
     
  41. ThunderStormEntertainment

    ThunderStormEntertainment

    Joined:
    May 19, 2019
    Posts:
    3
    You can also just reimport the Unity UI package, go into the Packages folder in the editor, right click in the Unity UI folder and click in reimport, then restart unity
     
  42. megatechno607

    megatechno607

    Joined:
    Aug 18, 2021
    Posts:
    3
    Go to the "GameObject" at the top menu, You will find UI at the very bottom there.I hope it will help
     
  43. ravi56

    ravi56

    Joined:
    Sep 15, 2021
    Posts:
    7
    Click on Assest and than Reimport all assest ,it will proberly solve the issue
     
  44. ManieBesselaar

    ManieBesselaar

    Joined:
    Nov 1, 2018
    Posts:
    30
    Hi all . I have a work around . Firstly I tried the following solutions from this thread.
    Restarting unity. No Joy.
    Removing and re installing TextMeshPro and unity ui. No joy.
    Reverting unity hub. Did not try.

    Workaround:
    For a text box or tmpro text box . Find your canvas in scene and right Click it. Create empty game object. Then in inspector just click ad component and find text, textmesh pro (ui) or whatever you need.
    A little clunky , but it works .
    Hope this helps someone until the issue is fixed.
    Ps. Has anyone filed a bug report on this one?
     
  45. UNITEDFUTURES

    UNITEDFUTURES

    Joined:
    Dec 7, 2012
    Posts:
    4
    Had the same issue. This solved it for me:
    1. Removed TextMeshPro Package
    2. Install TextMeshPro Package
    3. Quit Project
    4. Open Project
     
  46. Knbmedia

    Knbmedia

    Joined:
    Dec 8, 2014
    Posts:
    18
    Hi,
    I have now this problem after upgrading from 2020 to 2021.3.7f1: right click in the hierachy window does nothing and display an error in the console:

    Code (CSharp):
    1.  
    2. System.String.Substring (System.Int32 startIndex) (at <612a2c65aaf843d698f8d38b2ad7654a>:0)
    3. UnityEditor.SceneHierarchy.AddCreateGameObjectItemsToMenu (UnityEditor.GenericMenu menu, UnityEngine.Object[] context, System.Boolean includeCreateEmptyChild, System.Boolean useCreateEmptyParentMenuItem, System.Boolean includeGameObjectInPath, System.Int32 targetSceneHandle, UnityEditor.MenuUtils+ContextMenuOrigin origin) (at /Users/bokken/buildslave/unity/build/Editor/Mono/SceneHierarchy.cs:882)
    4. UnityEditor.SceneHierarchy.CreateGameObjectContextClick (UnityEditor.GenericMenu menu, System.Int32 contextClickedItemID) (at /Users/bokken/buildslave/unity/build/Editor/Mono/SceneHierarchy.cs:1300)
    5. UnityEditor.SceneHierarchy.ItemContextClick (System.Int32 contextClickedItemID) (at /Users/bokken/buildslave/unity/build/Editor/Mono/SceneHierarchy.cs:1561)
    6. UnityEditor.IMGUI.Controls.TreeViewController.HandleUnusedMouseEventsForItem (UnityEngine.Rect rect, UnityEditor.IMGUI.Controls.TreeViewItem item, System.Int32 row) (at /Users/bokken/buildslave/unity/build/Editor/Mono/GUI/TreeView/TreeViewController.cs:515)
    7. UnityEditor.IMGUI.Controls.TreeViewController.DoItemGUI (UnityEditor.IMGUI.Controls.TreeViewItem item, System.Int32 row, System.Single rowWidth, System.Boolean hasFocus) (at /Users/bokken/buildslave/unity/build/Editor/Mono/GUI/TreeView/TreeViewController.cs:594)
    8. UnityEditor.IMGUI.Controls.TreeViewController.IterateVisibleItems (System.Int32 firstRow, System.Int32 numVisibleRows, System.Single rowWidth, System.Boolean hasFocus) (at /Users/bokken/buildslave/unity/build/Editor/Mono/GUI/TreeView/TreeViewController.cs:837)
    9. UnityEditor.IMGUI.Controls.TreeViewController.OnGUI (UnityEngine.Rect rect, System.Int32 keyboardControlID) (at /Users/bokken/buildslave/unity/build/Editor/Mono/GUI/TreeView/TreeViewController.cs:727)
    10. UnityEditor.SceneHierarchy.DoTreeView (System.Single searchPathHeight) (at /Users/bokken/buildslave/unity/build/Editor/Mono/SceneHierarchy.cs:845)
    11. UnityEditor.SceneHierarchy.OnGUI (UnityEngine.Rect rect) (at /Users/bokken/buildslave/unity/build/Editor/Mono/SceneHierarchy.cs:625)
    12. UnityEditor.SceneHierarchyWindow.DoSceneHierarchy () (at /Users/bokken/buildslave/unity/build/Editor/Mono/SceneHierarchyWindow.cs:159)
    13. UnityEditor.SceneHierarchyWindow.OnGUI () (at /Users/bokken/buildslave/unity/build/Editor/Mono/SceneHierarchyWindow.cs:140)
    14. UnityEditor.HostView.InvokeOnGUI (UnityEngine.Rect onGUIPosition) (at /Users/bokken/buildslave/unity/build/Editor/Mono/HostView.cs:448)
    15. UnityEditor.DockArea.DrawView (UnityEngine.Rect dockAreaRect) (at /Users/bokken/buildslave/unity/build/Editor/Mono/GUI/DockArea.cs:387)
    16. UnityEditor.DockArea.OldOnGUI () (at /Users/bokken/buildslave/unity/build/Editor/Mono/GUI/DockArea.cs:378)
    17. UnityEngine.UIElements.IMGUIContainer.DoOnGUI (UnityEngine.Event evt, UnityEngine.Matrix4x4 parentTransform, UnityEngine.Rect clippingRect, System.Boolean isComputingLayout, UnityEngine.Rect layoutSize, System.Action onGUIHandler, System.Boolean canAffectFocus) (at /Users/bokken/buildslave/unity/build/ModuleOverrides/com.unity.ui/Core/IMGUIContainer.cs:372)
    18. UnityEngine.UIElements.IMGUIContainer.HandleIMGUIEvent (UnityEngine.Event e, UnityEngine.Matrix4x4 worldTransform, UnityEngine.Rect clippingRect, System.Action onGUIHandler, System.Boolean canAffectFocus) (at /Users/bokken/buildslave/unity/build/ModuleOverrides/com.unity.ui/Core/IMGUIContainer.cs:693)
    19. UnityEngine.UIElements.IMGUIContainer.HandleIMGUIEvent (UnityEngine.Event e, System.Action onGUIHandler, System.Boolean canAffectFocus) (at /Users/bokken/buildslave/unity/build/ModuleOverrides/com.unity.ui/Core/IMGUIContainer.cs:665)
    20. UnityEngine.UIElements.IMGUIContainer.HandleIMGUIEvent (UnityEngine.Event e, System.Boolean canAffectFocus) (at /Users/bokken/buildslave/unity/build/ModuleOverrides/com.unity.ui/Core/IMGUIContainer.cs:658)
    21. UnityEngine.UIElements.IMGUIContainer.SendEventToIMGUIRaw (UnityEngine.UIElements.EventBase evt, System.Boolean canAffectFocus, System.Boolean verifyBounds) (at /Users/bokken/buildslave/unity/build/ModuleOverrides/com.unity.ui/Core/IMGUIContainer.cs:618)
    22. UnityEngine.UIElements.IMGUIContainer.SendEventToIMGUI (UnityEngine.UIElements.EventBase evt, System.Boolean canAffectFocus, System.Boolean verifyBounds) (at /Users/bokken/buildslave/unity/build/ModuleOverrides/com.unity.ui/Core/IMGUIContainer.cs:607)
    23. UnityEngine.UIElements.IMGUIContainer.HandleEvent (UnityEngine.UIElements.EventBase evt) (at /Users/bokken/buildslave/unity/build/ModuleOverrides/com.unity.ui/Core/IMGUIContainer.cs:535)
    24. UnityEngine.UIElements.EventDispatchUtilities.PropagateEvent (UnityEngine.UIElements.EventBase evt) (at /Users/bokken/buildslave/unity/build/ModuleOverrides/com.unity.ui/Core/Events/IEventDispatchingStrategy.cs:113)
    25. UnityEngine.UIElements.MouseEventDispatchingStrategy.SendEventToRegularTarget (UnityEngine.UIElements.EventBase evt, UnityEngine.UIElements.BaseVisualElementPanel panel) (at /Users/bokken/buildslave/unity/build/ModuleOverrides/com.unity.ui/Core/Events/MouseEventDispatchingStrategy.cs:35)
    26. UnityEngine.UIElements.MouseEventDispatchingStrategy.SendEventToTarget (UnityEngine.UIElements.EventBase evt, UnityEngine.UIElements.BaseVisualElementPanel panel) (at /Users/bokken/buildslave/unity/build/ModuleOverrides/com.unity.ui/Core/Events/MouseEventDispatchingStrategy.cs:26)
    27. UnityEngine.UIElements.MouseEventDispatchingStrategy.DispatchEvent (UnityEngine.UIElements.EventBase evt, UnityEngine.UIElements.IPanel iPanel) (at /Users/bokken/buildslave/unity/build/ModuleOverrides/com.unity.ui/Core/Events/MouseEventDispatchingStrategy.cs:19)
    28. UnityEngine.UIElements.EventDispatcher.ApplyDispatchingStrategies (UnityEngine.UIElements.EventBase evt, UnityEngine.UIElements.IPanel panel, System.Boolean imguiEventIsInitiallyUsed) (at /Users/bokken/buildslave/unity/build/ModuleOverrides/com.unity.ui/Core/EventDispatcher.cs:381)
    29. UnityEngine.UIElements.EventDispatcher.ProcessEvent (UnityEngine.UIElements.EventBase evt, UnityEngine.UIElements.IPanel panel) (at /Users/bokken/buildslave/unity/build/ModuleOverrides/com.unity.ui/Core/EventDispatcher.cs:344)
    30. UnityEngine.UIElements.EventDispatcher.Dispatch (UnityEngine.UIElements.EventBase evt, UnityEngine.UIElements.IPanel panel, UnityEngine.UIElements.DispatchMode dispatchMode) (at /Users/bokken/buildslave/unity/build/ModuleOverrides/com.unity.ui/Core/EventDispatcher.cs:222)
    31. UnityEngine.UIElements.BaseVisualElementPanel.SendEvent (UnityEngine.UIElements.EventBase e, UnityEngine.UIElements.DispatchMode dispatchMode) (at /Users/bokken/buildslave/unity/build/ModuleOverrides/com.unity.ui/Core/Panel.cs:419)
    32. UnityEngine.UIElements.UIElementsUtility.DoDispatch (UnityEngine.UIElements.BaseVisualElementPanel panel) (at /Users/bokken/buildslave/unity/build/ModuleOverrides/com.unity.ui/Core/UIElementsUtility.cs:468)
    33. UnityEngine.UIElements.UIElementsUtility.UnityEngine.UIElements.IUIElementsUtility.ProcessEvent (System.Int32 instanceID, System.IntPtr nativeEventPtr, System.Boolean& eventHandled) (at /Users/bokken/buildslave/unity/build/ModuleOverrides/com.unity.ui/Core/UIElementsUtility.cs:211)
    34. UnityEngine.UIElements.UIEventRegistration.ProcessEvent (System.Int32 instanceID, System.IntPtr nativeEventPtr) (at /Users/bokken/buildslave/unity/build/ModuleOverrides/com.unity.ui/Core/UIElementsUtility.cs:74)
    35. UnityEngine.UIElements.UIEventRegistration+<>c.<.cctor>b__1_2 (System.Int32 i, System.IntPtr ptr) (at /Users/bokken/buildslave/unity/build/ModuleOverrides/com.unity.ui/Core/UIElementsUtility.cs:28)
    36. UnityEngine.GUIUtility.ProcessEvent (System.Int32 instanceID, System.IntPtr nativeEventPtr, System.Boolean& result) (at /Users/bokken/buildslave/unity/build/Modules/IMGUI/GUIUtility.cs:189)
    37.  
    If I uninstall TextMeshPro: right click works.
    But the bug occurs again after reinstalling it.
    I tried a lot of things (reimport all, delete library folder) but nothing works.
    Any ideas?

    EDIT:
    After testing, it's not TextMeshPro: when removing it, i got console errors (because some of my scripts use it) then right click works.
    I have the same behavior if I remove In App Purchasing for example: I got error in my scripts but right click works.
    Only when reinstalling packages so no more errors then right click does not work.
    I think that Unity stops loading some stuff when errors linked to packages appear so right click works at this moment.

    EDIT 2:
    Finally, I found that an Editor script from on old asset was causing this strange bug.
    No idea why. I found this Editor script when removing all my Unity assets one by one...
     
    Last edited: Sep 8, 2022
  47. bhushanshetye81

    bhushanshetye81

    Joined:
    Feb 12, 2023
    Posts:
    1

    Perfect solution i have :-

    Go to windows - then select package manager - then there is name like package: in project select it and change to unity registry , then search for text mesh pro and install it and unity UI also.
     
  48. gamesbydre

    gamesbydre

    Joined:
    Nov 25, 2014
    Posts:
    58
    Just remove and reinstall textmesh pro for urp users
     
  49. HadezBlue

    HadezBlue

    Joined:
    Nov 19, 2023
    Posts:
    1
    Your comment saved me after 2 hours of looking online. Thank you!