Accessing Editor Window from Game Code

I have a custom editor window which I made in unity 3.5. I wanna know if there’s any way I could open up that window from the Game Code when the Game is Playing. I have read through the blogs but I cudn’t find anything that allows me to access my editor script from the game code.

In general it isn’t possible since the UnityEditor namespace isn’t available at runtime. If you use anything from there you can’t build your game. However you can use platform dependent compilation to open your editor window. Of course this will only work when you play your game inside the editor. When you build your game the code between #if and #endif
will be automatically removed.

//C#
void Update()
{
    if (Input.GetKeyDown(KeyCode.A))
    {
        #if UNITY_EDITOR
        UnityEditor.EditorWindow.GetWindow<YourEditorWindow>();
        #endif
    }
}