VBE - reset windows view?

itr674

Well-known Member
Joined
Apr 10, 2002
Messages
1,790
Office Version
  1. 2016
Platform
  1. Windows
I messed up my VBE view a minute ago and can't get it back?

I think this is the DEFAULT VBE view?

1. Project Explorer in the uppr left corner.

2. Proerties window was under the Project Explorer

3. Code window was on the Right.
 
Well I have them back a they origninally were.

The last thing I did was turn them all off, undock them all then turn them all back on and they are back???

Have no idea what I really did--well some where in there I did some tile verticals and horizontals, and them maximized windows and some more stuff...
 
Upvote 0

Excel Facts

Is there a shortcut key for strikethrough?
Ctrl+S is used for Save. Ctrl+5 is used for Strikethrough. Why Ctrl+5? When you use hashmarks to count |||| is 4, strike through to mean 5.
TommyGun - thanks a bunch, by the way that looks like an AR not a TommyGun...
 
Upvote 0
Yeah, I know, but I love the penguin! :lol:

I love watching old gangsta movies set in the 20's with the old Ford's and the TommyGun's! :diablo:
 
Upvote 0
This is as close as I can get for now using a macro... adding the Window to the LinkedWindows collection adds it to the "bottom" of the window, and I still don't know how to "drag" it to the right...

<font face=Courier New><SPAN style="color:#00007F">Option</SPAN> <SPAN style="color:#00007F">Explicit</SPAN>
<SPAN style="color:#00007F">Option</SPAN> <SPAN style="color:#00007F">Base</SPAN> 1

<SPAN style="color:#00007F">Sub</SPAN> ResetVBEState()
    <SPAN style="color:#00007F">Dim</SPAN> Win <SPAN style="color:#00007F">As</SPAN> VBIDE.Window
    <SPAN style="color:#00007F">Dim</SPAN> Found <SPAN style="color:#00007F">As</SPAN> <SPAN style="color:#00007F">Boolean</SPAN>
    <SPAN style="color:#00007F">Dim</SPAN> i <SPAN style="color:#00007F">As</SPAN> <SPAN style="color:#00007F">Long</SPAN>
    <SPAN style="color:#00007F">Dim</SPAN> Ar <SPAN style="color:#00007F">As</SPAN> <SPAN style="color:#00007F">Variant</SPAN>
    
    Ar = Array(6, 7)    <SPAN style="color:#007F00">'Window type of Project and Property windows</SPAN>
    <SPAN style="color:#007F00">'Let's find in the "docked" windows</SPAN>
    <SPAN style="color:#00007F">For</SPAN> i = <SPAN style="color:#00007F">LBound</SPAN>(Ar) <SPAN style="color:#00007F">To</SPAN> <SPAN style="color:#00007F">UBound</SPAN>(Ar)
        Found = <SPAN style="color:#00007F">False</SPAN>
        <SPAN style="color:#00007F">For</SPAN> <SPAN style="color:#00007F">Each</SPAN> Win <SPAN style="color:#00007F">In</SPAN> .MainWindow.LinkedWindows
            <SPAN style="color:#00007F">If</SPAN> Win.Type = Ar(i) <SPAN style="color:#00007F">Then</SPAN>
                Found = <SPAN style="color:#00007F">True</SPAN>
                <SPAN style="color:#00007F">Exit</SPAN> <SPAN style="color:#00007F">For</SPAN>
            <SPAN style="color:#00007F">End</SPAN> <SPAN style="color:#00007F">If</SPAN>
        <SPAN style="color:#00007F">Next</SPAN> Win
        <SPAN style="color:#00007F">If</SPAN> <SPAN style="color:#00007F">Not</SPAN> Found <SPAN style="color:#00007F">Then</SPAN>
            <SPAN style="color:#00007F">For</SPAN> <SPAN style="color:#00007F">Each</SPAN> Win <SPAN style="color:#00007F">In</SPAN> .Windows
                <SPAN style="color:#00007F">If</SPAN> Win.Type = Ar(i) <SPAN style="color:#00007F">Then</SPAN>
                    Win.Visible = <SPAN style="color:#00007F">True</SPAN>
                    <SPAN style="color:#00007F">On</SPAN> <SPAN style="color:#00007F">Error</SPAN> <SPAN style="color:#00007F">Resume</SPAN> <SPAN style="color:#00007F">Next</SPAN>
                    .MainWindow.LinkedWindows.Remove Win
                    <SPAN style="color:#00007F">On</SPAN> <SPAN style="color:#00007F">Error</SPAN> <SPAN style="color:#00007F">GoTo</SPAN> 0
                    Win.Left = 1
                    Win.Top = Choose(i, 125, 429)
                    Win.Height = 307
                    Win.Width = 186
                    <SPAN style="color:#00007F">Exit</SPAN> <SPAN style="color:#00007F">For</SPAN>
                <SPAN style="color:#00007F">End</SPAN> <SPAN style="color:#00007F">If</SPAN>
            <SPAN style="color:#00007F">Next</SPAN> Win
        <SPAN style="color:#00007F">End</SPAN> <SPAN style="color:#00007F">If</SPAN>
    <SPAN style="color:#00007F">Next</SPAN> i
<SPAN style="color:#00007F">End</SPAN> <SPAN style="color:#00007F">Sub</SPAN></FONT>
 
Upvote 0
Juan Pablo González - thanks for code will put in my personal macro workbook...
 
Upvote 0
Juan Pablo González - thanks for code will put in my personal macro workbook...

For me it was as simple as double clicking the title bar of (whatever) window to break it free from its present unwanted location. This makes your window floating and dragable. It's Probably one of those standard Office/Windows things that many people (including yours truly) don't know.

Next thing to do, make sure the window in question is set to dockable (Tools, settings, docking). Now simply drag it left, right or wherever you want it and, when the temporary guidelines occur to indicate that docking position has been reached, release your mouse button.

Check this link for full details:

Docking VBE Windows

Prebez
 
Upvote 0
I'd love to know how to reset the defaults (docking and position) because I've messed mine up too.

If it' just a case of not being able to see them choose View|Project Explorer (Ctrl+R) and View|Properties Window (F4).



Not sure if this is what is going on but wanted to reply in case it is as I had the same issue & was able to fix it..

Issue - Normally when you view the properties window in excel vba 2003 it is stationed/ docked to the lower left hand side of the screen under the project explorer section however now it is free floating & no longer docked.
Solution- First make sure you see the project explorer & properties window on the screen. If you do not, then go to view & select them for viewing. Then LEFT Click & Hold on the top of the properties window where it says "Properties - VBAProject" at that point it should be active & you should be able to move it... Then simply drag & drop it towards the top left side of the screen where it say "Project - VBA Project" (note you should see 3 little icons that look like folders)... Around/ At that point you should drop it & it should then become docked & you can then move it above or below the project explorer rather easily as you prefer..

On a separate note, the Folder icons i mentioned earlier at the top of the project explorer section, the 3rd one that looks just like a file folder is used to set the viewing settings of the vba projects.. When you have it selected it breaks out/ separates worksheet objs, classes, userforms, & modules into subfolders... had a hell of time once figuring that out when I accidently hit it and all the subfolders went away..

Nonetheless hope this helps someone as you all have often helped me a great deal & it is much appreciated!
 
Upvote 0
Hello,

In case someone still have this issue, I managed to reset my VBE windows following this procedure :
The only way I know how to accomplish this is to edit the registry.

Close All Office programs
Open a command prompt and type regedit
Navigate to HKEY_CURRENTUSER\Software\Microsoft\VBA\6.0\Common
Right click on Common and Export to save the *.reg file somewhere safe. This is your back up. Double clicking this file will restore your current settings.
Right click on Common and Delete it. Doing this will remove all of its subkeys that hold your personal settings.
The "Common" key will be recreated the next time you close the VBA Editor along with any changes to the settings you may make.

Cheers.
 
Upvote 0

Forum statistics

Threads
1,224,823
Messages
6,181,176
Members
453,021
Latest member
Justyna P

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Back
Top