Weird gray line at top of screen

B

Bruce001

I am having a strange problem that I can't figure out using the
debugger. When I run my code, a gray line appears at the top of the
screen. When I step through the code using the debugger, it doesn't
appear. Once the line appears, it doesn't go away. It covers the top
two rows of my screen.

First, some background. My application is separated into 3 workbooks
that span across network drives. I have a launcher workbook that makes
sure macros are enabled and it opens a pricing file as read only so a
bunch of users can get to the same file at once. It then launches my
workbook which contains the bulk of the application.

Upon entering the application, I execute the following code in the
workbook open phase:

APPLICATION.COMMANDBARS.ACTIVEMENUBAR.ENABLED = FALSE
APPLICATION.DISPLAYFULLSCREEN = TRUE
APPLICATION.COMMANDBARS(\"FULL SCREEN\").ENABLED = FALSE
I do this to prevent my users from accessing any menus. I do other
things, but I think these lines of code are leading to my gray line
problem.

Anyway, inside my application, I allow the user to open a text file
which populates values across about 30 sheets inside the workbook. It
is when I close this input file that I get the gray line that won't go
away.

I have tried:

APPLICATION.SCREENUPDATING = FALSE

Just leaving the text file open

and about a dozen other things.

Any help would be greatly appreciated.

Bruce Gold
 
B

Bruce001

Just bumping this back to the top. I am still having the problem. I ha
a partial success when I ran this before I opened the text file:

Application.CommandBars.ActiveMenuBar.Enabled = True
Application.CommandBars("Full Screen").Enabled = True
Application.DisplayFullScreen = False

And then turned it back on after closing the file. But the gray lin
would appear after switching a few times between sheets.

Is there a better way of getting rid of the menu bars, tool bars, etc
out there
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top