Search Unity

  1. Unity 2018.1 has arrived! Read about it here
    Dismiss Notice
  2. Scriptable Render Pipeline improvements, Texture Mipmap Streaming, and more! Check out what we have in store for you in the 2018.2 Beta.
    Dismiss Notice
  3. If you couldn't join the live stream, take a peek at what you missed.
    Dismiss Notice
  4. Improve your Unity skills with a certified instructor in a private, interactive classroom. Learn more.
    Dismiss Notice
  5. ARCore is out of developer preview! Read about it here.
    Dismiss Notice
  6. 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
  7. Want to see the most recent patch releases? Take a peek at the patch release page.
    Dismiss Notice

Invalid Editor Window

Discussion in 'Editor & General Support' started by nekroadmin, Sep 9, 2011.

  1. nekroadmin

    nekroadmin

    Joined:
    Apr 22, 2011
    Posts:
    22
    Hey guys, i get this error:
    Invalid editor window UnityEditor.FallbackEditorWindow

    ...but i don't know where it come from and yes, I have a custom EditorWindow.
    But I get this error when in run-time. If i click this error it just opens the Mono IDE but i doesn't show me the line or the scirpt where the error comes.

    Sorry for my bad English... Greek here! :p

    Thanks in advance
    Mike
     
    Last edited: Sep 9, 2011
  2. Shigeru

    Shigeru

    Joined:
    Sep 7, 2011
    Posts:
    32
    could you please describe the problem a bit more detailed?

    Or attach some screenshots?

    Maybe you could send me your project files so I can have a look at it.

    Which unity version are you using?

    Shigeru
     
  3. nekroadmin

    nekroadmin

    Joined:
    Apr 22, 2011
    Posts:
    22
    3.4 Ver.

    I just run the game from the editor and i get that error. I have an EditorWindow that i have made but i don't get that error while not running the game. I don't think you need screenshots coz it doesn't do anything in the game. it doesn't crash, just shows that error message.
     
  4. Shigeru

    Shigeru

    Joined:
    Sep 7, 2011
    Posts:
    32
    Did you tried using an empty project?

    How did you made that editorwindow?

    Shigeru
     
  5. nekroadmin

    nekroadmin

    Joined:
    Apr 22, 2011
    Posts:
    22
    public class ControlWindow : EditorWindow {
    Vector2 texturePosition = new Vector2(0,0);

    [MenuItem ("Window/Control System")]
    static void ShowWindow(){
    EditorWindow.GetWindow(typeof(ControlWindow), false, "Texture Controller");
    }

    void OnGUI(){
    texturePosition = EditorGUILayout.Vector2Field( "Position:", texturePosition );

    if ( GUILayout.Button( "Show Position" ) )
    Debug.Log(texturePosition);
    }
    }

    This is a small piece of code. The thing is that it works FINE with NO ERRORS! But in runtime instead of the closed editorwindow, it shows that error. :-/
     
  6. tutibueno

    tutibueno

    Joined:
    Dec 11, 2009
    Posts:
    9
    You must put all editor scripts inside Assets/Editor folder. If it doesn't exist, create one and put your script inside there.
     
  7. cecarlsen

    cecarlsen

    Joined:
    Jun 30, 2006
    Posts:
    426
    I get the same error. Pretty annoying. Shouldn't it be possible to put Editor folders wherever you want inside subfolders of the Assets folder?

    ~ce
     
  8. Dreamora

    Dreamora

    Joined:
    Apr 5, 2008
    Posts:
    26,596
    it used to be possible but I am not sure it still holds actually as per 3.4
    During unity 3 a lot of that stuff changed and with 3.4 quite a bit also in form of the solutions so check in which project it ends, that says it all
     
  9. antenna-tree

    antenna-tree

    Joined:
    Oct 30, 2005
    Posts:
    5,325
    Yes, you should be able to put Editor folders anywhere in the Assets folder (with the exception of Resources folder maybe). If this isn't the case it's a bug so please submit a bug report with an example.
     
  10. ravinder

    ravinder

    Joined:
    Aug 25, 2010
    Posts:
    150
    Just in case if the problem still persists ,reset the window factory settings inside the Unity editor which is available in the right top corner where you set your layout.

    Here is a screenshot
    $Screen Shot 2012-03-23 at 10.21.33 PM.png

    The solution worked for me, hope it does for everyone else.
    Do not forget to reply to this post as a solution to this thread if it solved your problem so that others may also get to know.
     
  11. Innovative

    Innovative

    Joined:
    Jan 13, 2013
    Posts:
    4
    Thanks ravinder, I had the following error and your solution cleared up the problem:

    Invalid editor window UnityEditor.FallbackEditorWindow UnityEditor.EditorApplication:Internal_CallGlobalEventHandler()

    The error message would appear when I maximized any editor window and then minimized again. I thought it was in my code so after hours of searching I was happy to find your answer.
     
  12. Pratap-Dafedar

    Pratap-Dafedar

    Joined:
    Aug 30, 2013
    Posts:
    19
    Cool Ravinder. It worked for me...
     
  13. Spelmyst

    Spelmyst

    Joined:
    Dec 10, 2011
    Posts:
    7
    Good call Ravinder. Your suggestion worked for me. :)

    This happened after I imported the Stealth Package.
     
  14. Rainking

    Rainking

    Joined:
    Jun 10, 2013
    Posts:
    39
    Reverting to factory setting also helped fixing this! Thx
     
  15. Stephen_O

    Stephen_O

    Joined:
    Jun 8, 2013
    Posts:
    593
    From what I understand..

    This happens when you have an editor window referenced by the editor that doesn't know how to behave, example using custom editor windows and closing unity, then reopen without the code compiled, perhaps you deleted the asset you were now finished with; or using a different layout that cant be reproduced when Unity is reopened because some reference is missing.

    It happened to me in 5.3.
     
  16. Skyblade

    Skyblade

    Joined:
    Nov 19, 2013
    Posts:
    23
    According to this stackoverflow post http://stackoverflow.com/a/23313182 EditorWindow.GetWindow() also affected by this, but you simply need to reset Layout to any predefined preset.
    Annoying bug.
     
  17. arfan447

    arfan447

    Joined:
    Oct 26, 2015
    Posts:
    7
    Reverting to factory setting is best way to remove this error.....
     
  18. valonsoft

    valonsoft

    Joined:
    May 22, 2016
    Posts:
    2
    Thanks man ... works here
     
  19. JoltBug

    JoltBug

    Joined:
    Jul 11, 2016
    Posts:
    8
    Cool Ravinder, worked like a charm. Thanks man.