Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 29
Default Worksheet Focus

Hello clever people!

I have a project which collects and writes information to various worksheets
within the file, what I would like to do is keep the focus on the "front
cover" sheet. The front cover sheet has the links to all the userforms etc
to run, but I would like to keep the focus set on this sheet so it looks
pretty for the users!

I'm am sure there is an easy way to do this but I can't for the life of me
find it - maybe it's just too late in the day!

--
Zani
(if I have posted here, I really am stuck!)

  #2   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 27,285
Default Worksheet Focus

Unless you code moves the focus from this sheet, it will not change.

Instead of code like

Worksheets("Sheet2").Activate
Range("B9").Select
Selection.copy
Worksheets("Sheet3").Activate
Range("F2").Select
Activesheet.Paste

do colde like

Worksheets("Sheet2").Range("B9").copy _
Destination:=Worksheets("Sheet3").Range("F2")

The point is to avoid selecting. Use references to ranges.

--
Regards,
Tom Ogilvy


"Zani" wrote in message
...
Hello clever people!

I have a project which collects and writes information to various

worksheets
within the file, what I would like to do is keep the focus on the "front
cover" sheet. The front cover sheet has the links to all the userforms

etc
to run, but I would like to keep the focus set on this sheet so it looks
pretty for the users!

I'm am sure there is an easy way to do this but I can't for the life of me
find it - maybe it's just too late in the day!

--
Zani
(if I have posted here, I really am stuck!)



  #3   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 247
Default Worksheet Focus

if you set screen updating to false would this acccomplish the same thing??
--
paul
remove nospam for email addy!



"Tom Ogilvy" wrote:

Unless you code moves the focus from this sheet, it will not change.

Instead of code like

Worksheets("Sheet2").Activate
Range("B9").Select
Selection.copy
Worksheets("Sheet3").Activate
Range("F2").Select
Activesheet.Paste

do colde like

Worksheets("Sheet2").Range("B9").copy _
Destination:=Worksheets("Sheet3").Range("F2")

The point is to avoid selecting. Use references to ranges.

--
Regards,
Tom Ogilvy


"Zani" wrote in message
...
Hello clever people!

I have a project which collects and writes information to various

worksheets
within the file, what I would like to do is keep the focus on the "front
cover" sheet. The front cover sheet has the links to all the userforms

etc
to run, but I would like to keep the focus set on this sheet so it looks
pretty for the users!

I'm am sure there is an easy way to do this but I can't for the life of me
find it - maybe it's just too late in the day!

--
Zani
(if I have posted here, I really am stuck!)




  #4   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 5,302
Default Worksheet Focus

Hi Paul,

if you set screen updating to false would this acccomplish the same
thing??

No, setting ScreenUpdating to False does not prevent selections and does
nothing to ensure that the required sheet remains, or becomes the active
sheet; it merely prevents the screen from being redrawn, thus rendering such
selections invisible.

Tom's suggestion was to remove unnecessary selections and represented a
solution; disabling ScreenUpdating provides a visual palliative to a
concomitant problem of selections, but does nothing to resolve the OP's
intrinsic problem.


---
Regards,
Norman


"paul" wrote in message
...
if you set screen updating to false would this acccomplish the same
thing??
--
paul
remove nospam for email addy!



"Tom Ogilvy" wrote:

Unless you code moves the focus from this sheet, it will not change.

Instead of code like

Worksheets("Sheet2").Activate
Range("B9").Select
Selection.copy
Worksheets("Sheet3").Activate
Range("F2").Select
Activesheet.Paste

do colde like

Worksheets("Sheet2").Range("B9").copy _
Destination:=Worksheets("Sheet3").Range("F2")

The point is to avoid selecting. Use references to ranges.

--
Regards,
Tom Ogilvy


"Zani" wrote in message
...
Hello clever people!

I have a project which collects and writes information to various

worksheets
within the file, what I would like to do is keep the focus on the
"front
cover" sheet. The front cover sheet has the links to all the userforms

etc
to run, but I would like to keep the focus set on this sheet so it
looks
pretty for the users!

I'm am sure there is an easy way to do this but I can't for the life of
me
find it - maybe it's just too late in the day!

--
Zani
(if I have posted here, I really am stuck!)






  #5   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 27,285
Default Worksheet Focus

hmmm, "palliative" eh.

Wasn't it in the Shawshank Redemption where Bubba spoke that immortal
phrase:

"Bend over and grab ahold of them thar screaming bars to palliate your
discomfort"

--
Regards,
Tom Ogilvy


"Norman Jones" wrote in message
...
Hi Paul,

if you set screen updating to false would this acccomplish the same
thing??

No, setting ScreenUpdating to False does not prevent selections and does
nothing to ensure that the required sheet remains, or becomes the active
sheet; it merely prevents the screen from being redrawn, thus rendering

such
selections invisible.

Tom's suggestion was to remove unnecessary selections and represented a
solution; disabling ScreenUpdating provides a visual palliative to a
concomitant problem of selections, but does nothing to resolve the OP's
intrinsic problem.


---
Regards,
Norman


"paul" wrote in message
...
if you set screen updating to false would this acccomplish the same
thing??
--
paul
remove nospam for email addy!



"Tom Ogilvy" wrote:

Unless you code moves the focus from this sheet, it will not change.

Instead of code like

Worksheets("Sheet2").Activate
Range("B9").Select
Selection.copy
Worksheets("Sheet3").Activate
Range("F2").Select
Activesheet.Paste

do colde like

Worksheets("Sheet2").Range("B9").copy _
Destination:=Worksheets("Sheet3").Range("F2")

The point is to avoid selecting. Use references to ranges.

--
Regards,
Tom Ogilvy


"Zani" wrote in message
...
Hello clever people!

I have a project which collects and writes information to various
worksheets
within the file, what I would like to do is keep the focus on the
"front
cover" sheet. The front cover sheet has the links to all the

userforms
etc
to run, but I would like to keep the focus set on this sheet so it
looks
pretty for the users!

I'm am sure there is an easy way to do this but I can't for the life

of
me
find it - maybe it's just too late in the day!

--
Zani
(if I have posted here, I really am stuck!)










  #6   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 5,302
Default Worksheet Focus

Hi Tom,

"Bend over and grab ahold of them thar screaming bars to palliate your
discomfort"


A wonderfully evocative quotation!

---
Regards,
Norman


"Tom Ogilvy" wrote in message
...
hmmm, "palliative" eh.

Wasn't it in the Shawshank Redemption where Bubba spoke that immortal
phrase:

"Bend over and grab ahold of them thar screaming bars to palliate your
discomfort"

--
Regards,
Tom Ogilvy



  #7   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 35,218
Default Worksheet Focus

You sure it wasn't "Old Yeller"....




Tom Ogilvy wrote:

hmmm, "palliative" eh.

Wasn't it in the Shawshank Redemption where Bubba spoke that immortal
phrase:

"Bend over and grab ahold of them thar screaming bars to palliate your
discomfort"

--
Regards,
Tom Ogilvy

"Norman Jones" wrote in message
...
Hi Paul,

if you set screen updating to false would this acccomplish the same
thing??

No, setting ScreenUpdating to False does not prevent selections and does
nothing to ensure that the required sheet remains, or becomes the active
sheet; it merely prevents the screen from being redrawn, thus rendering

such
selections invisible.

Tom's suggestion was to remove unnecessary selections and represented a
solution; disabling ScreenUpdating provides a visual palliative to a
concomitant problem of selections, but does nothing to resolve the OP's
intrinsic problem.


---
Regards,
Norman


"paul" wrote in message
...
if you set screen updating to false would this acccomplish the same
thing??
--
paul
remove nospam for email addy!



"Tom Ogilvy" wrote:

Unless you code moves the focus from this sheet, it will not change.

Instead of code like

Worksheets("Sheet2").Activate
Range("B9").Select
Selection.copy
Worksheets("Sheet3").Activate
Range("F2").Select
Activesheet.Paste

do colde like

Worksheets("Sheet2").Range("B9").copy _
Destination:=Worksheets("Sheet3").Range("F2")

The point is to avoid selecting. Use references to ranges.

--
Regards,
Tom Ogilvy


"Zani" wrote in message
...
Hello clever people!

I have a project which collects and writes information to various
worksheets
within the file, what I would like to do is keep the focus on the
"front
cover" sheet. The front cover sheet has the links to all the

userforms
etc
to run, but I would like to keep the focus set on this sheet so it
looks
pretty for the users!

I'm am sure there is an easy way to do this but I can't for the life

of
me
find it - maybe it's just too late in the day!

--
Zani
(if I have posted here, I really am stuck!)







--

Dave Peterson
  #8   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 27,285
Default Worksheet Focus

It could have been, but Old Yeller really couldn't grab ahold so it seems
less likely. Of couse I was only around 8 back then, so may have missed it
or may have been up getting popcorn during that part. Then again, they tend
to reuse the really good lines.

--
Regards,
Tom Ogilvy





"Dave Peterson" wrote in message
...
You sure it wasn't "Old Yeller"....




Tom Ogilvy wrote:

hmmm, "palliative" eh.

Wasn't it in the Shawshank Redemption where Bubba spoke that immortal
phrase:

"Bend over and grab ahold of them thar screaming bars to palliate your
discomfort"

--
Regards,
Tom Ogilvy

"Norman Jones" wrote in message
...
Hi Paul,

if you set screen updating to false would this acccomplish the same
thing??
No, setting ScreenUpdating to False does not prevent selections and

does
nothing to ensure that the required sheet remains, or becomes the

active
sheet; it merely prevents the screen from being redrawn, thus

rendering
such
selections invisible.

Tom's suggestion was to remove unnecessary selections and represented

a
solution; disabling ScreenUpdating provides a visual palliative to a
concomitant problem of selections, but does nothing to resolve the

OP's
intrinsic problem.


---
Regards,
Norman


"paul" wrote in message
...
if you set screen updating to false would this acccomplish the same
thing??
--
paul
remove nospam for email addy!



"Tom Ogilvy" wrote:

Unless you code moves the focus from this sheet, it will not

change.

Instead of code like

Worksheets("Sheet2").Activate
Range("B9").Select
Selection.copy
Worksheets("Sheet3").Activate
Range("F2").Select
Activesheet.Paste

do colde like

Worksheets("Sheet2").Range("B9").copy _
Destination:=Worksheets("Sheet3").Range("F2")

The point is to avoid selecting. Use references to ranges.

--
Regards,
Tom Ogilvy


"Zani" wrote in message
...
Hello clever people!

I have a project which collects and writes information to various
worksheets
within the file, what I would like to do is keep the focus on the
"front
cover" sheet. The front cover sheet has the links to all the

userforms
etc
to run, but I would like to keep the focus set on this sheet so

it
looks
pretty for the users!

I'm am sure there is an easy way to do this but I can't for the

life
of
me
find it - maybe it's just too late in the day!

--
Zani
(if I have posted here, I really am stuck!)







--

Dave Peterson



  #9   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 35,218
Default Worksheet Focus

Off to check IMDB.com.

Nope, I must be wrong <vvbg.

Tom Ogilvy wrote:

It could have been, but Old Yeller really couldn't grab ahold so it seems
less likely. Of couse I was only around 8 back then, so may have missed it
or may have been up getting popcorn during that part. Then again, they tend
to reuse the really good lines.

--
Regards,
Tom Ogilvy

"Dave Peterson" wrote in message
...
You sure it wasn't "Old Yeller"....




Tom Ogilvy wrote:

hmmm, "palliative" eh.

Wasn't it in the Shawshank Redemption where Bubba spoke that immortal
phrase:

"Bend over and grab ahold of them thar screaming bars to palliate your
discomfort"

--
Regards,
Tom Ogilvy

"Norman Jones" wrote in message
...
Hi Paul,

if you set screen updating to false would this acccomplish the same
thing??
No, setting ScreenUpdating to False does not prevent selections and

does
nothing to ensure that the required sheet remains, or becomes the

active
sheet; it merely prevents the screen from being redrawn, thus

rendering
such
selections invisible.

Tom's suggestion was to remove unnecessary selections and represented

a
solution; disabling ScreenUpdating provides a visual palliative to a
concomitant problem of selections, but does nothing to resolve the

OP's
intrinsic problem.


---
Regards,
Norman


"paul" wrote in message
...
if you set screen updating to false would this acccomplish the same
thing??
--
paul
remove nospam for email addy!



"Tom Ogilvy" wrote:

Unless you code moves the focus from this sheet, it will not

change.

Instead of code like

Worksheets("Sheet2").Activate
Range("B9").Select
Selection.copy
Worksheets("Sheet3").Activate
Range("F2").Select
Activesheet.Paste

do colde like

Worksheets("Sheet2").Range("B9").copy _
Destination:=Worksheets("Sheet3").Range("F2")

The point is to avoid selecting. Use references to ranges.

--
Regards,
Tom Ogilvy


"Zani" wrote in message
...
Hello clever people!

I have a project which collects and writes information to various
worksheets
within the file, what I would like to do is keep the focus on the
"front
cover" sheet. The front cover sheet has the links to all the
userforms
etc
to run, but I would like to keep the focus set on this sheet so

it
looks
pretty for the users!

I'm am sure there is an easy way to do this but I can't for the

life
of
me
find it - maybe it's just too late in the day!

--
Zani
(if I have posted here, I really am stuck!)







--

Dave Peterson


--

Dave Peterson
Reply
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules

Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
Set Focus to Worksheet and then a specific ROW HotRod Excel Programming 1 November 11th 05 04:30 PM
Maintain focus on one worksheet while collecting data in others evilpixie Excel Programming 3 October 12th 05 10:39 PM
Option Button/Focus Problem on Worksheet Resume Next Excel Programming 4 September 20th 05 01:10 AM
Vying for the focus - Worksheet Vs Forms Adrian[_7_] Excel Programming 0 August 4th 04 04:20 PM
Set focus on graphic inserted in worksheet David Cuthill[_2_] Excel Programming 3 February 9th 04 07:45 PM


All times are GMT +1. The time now is 01:41 PM.

Powered by vBulletin® Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
Copyright ©2004-2024 ExcelBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Excel"