View Single Post
  #7   Report Post  
Piranha
 
Posts: n/a
Default


Mad Cow
Hi,
To stop the "whole spreadsheet blinks for a fraction of a second"
Put this at the start of your macro

Application.ScreenUpdating = False
'Turn screen updating off.

Then put this at the end of your macro

Application.ScreenUpdating = True
'Turn screen updating back on.

Thx
Dave


mad.cow Wrote:
Thanks for the message. CLR also responded and I was a bit confused at
first. However, I was able to try a few things and re-read the message
and I
did exactly what it said. I had the macro first go to somewhere far
away in
the spreadsheet, basically I went the far lower right part of the
spreadsheet, row 1000 and column IV. I created a name for that cell
as
"end_of_worksheet". Then in my macros, I first went to the end of the
worksheet, and then to the cell that I wanted and it worked perfectly.
The
whole spreadsheet blinks for a fraction of a second, but then it goes
right
where I wanted it to go.

The reason it would be difficult for me to use a VB command to shift up
or
down a specific number of cells is because this thing is constantly
growing.
It's also the reason that I created names for the sections. That way,
if I
have to add rows, I can and it won't destroy my macros.

"Biff" wrote:

Hi!

I have a similar setup in one of my files.

I'm not very good with VBA code but I used a line like this to fine

tune
where the active window ends up:

ActiveWindow.SmallScroll ToLeft:=2

Depending on what direction you want to move, replace ToLeft with

either
ToRight, Up or Down. It sounds like you want to go Up.

You'll have to experiment with the =?? value until you get it exactly

where
you want it.

Biff

"mad.cow" wrote in message
...
I have a spreadsheet price list with rows that contain headings in

them,
for
example, cables, displays, cabinets, etc. The spreadsheet has

grown to be
several hundred rows long, and I wanted to have a way to easily get

from
one
place to another without having to scroll around all the time. I

decided
that the best way to fix this would be to create macro buttons at

the top
few
rows of the screen that would take me to the particular sections in

the
worksheet. So I researched how to create names for a particular

cell, and
learned how to make a macro to goto that particular cell (using the

name).
Everything works out pretty good so far. I have freeze panes set

so that
my
macro buttons stay at the top of the screen at all times.

The problem is that when I run the macros, it only takes me to that

cell
and
if the cell happens to be anywhere lower on the spreadsheet than

what is
currently visible on the screen, it makes the cell appear at the

bottom of
the screen. Since my intention is to see the contents of the rows

just
under
this row heading, I'd like to find a way to make the cell come up

right
under
my frozen panes. I've searched high and low for some command to

bring
that
cell to the "top" (with the exception of the frozen panes) of the

screen.

Can anyone help me with this? It driving me nuts. Thanks.






--
Piranha
------------------------------------------------------------------------
Piranha's Profile: http://www.excelforum.com/member.php...o&userid=20435
View this thread: http://www.excelforum.com/showthread...hreadid=374846