PC Review


Reply
Thread Tools Rate Thread

Directional buttons

 
 
laingds@canada.com
Guest
Posts: n/a
 
      7th Sep 2011
I have a time sheet I want to put directional buttons on similar to a
calendar so you can move forward and backward to view different pay
periods.
Each pay period is 2 weeks long taking up 14 columns + 1 column for
NOTES + 1 column for a border, so every pay period is 16 columns wide.
Using the Macro Recorder in Excel 2007 it used this;
ActiveWindow.ScrollColumn = 21 or 37 or 53 etc. Could I count what
column the user is looking at and substitute the number after
ActiveWindow.ScrollColumn = with n+ or – 16 ?
Is this the best method for moving the focus for a user or can someone
suggest something better?
 
Reply With Quote
 
 
 
 
GS
Guest
Posts: n/a
 
      8th Sep 2011
(E-Mail Removed) brought next idea :
> I have a time sheet I want to put directional buttons on similar to a
> calendar so you can move forward and backward to view different pay
> periods.
> Each pay period is 2 weeks long taking up 14 columns + 1 column for
> NOTES + 1 column for a border, so every pay period is 16 columns wide.
> Using the Macro Recorder in Excel 2007 it used this;
> ActiveWindow.ScrollColumn = 21 or 37 or 53 etc. Could I count what
> column the user is looking at and substitute the number after
> ActiveWindow.ScrollColumn = with n+ or – 16 ?
> Is this the best method for moving the focus for a user or can someone
> suggest something better?


I can see where this isn't going to serve your purpose too well if
users use the tab key or arrow keys to navigate. Why can't they just
hold down the 'Alt' key while pressing PageUP (scroll left) or PageDn
(scroll right)?

--
Garry

Free usenet access at http://www.eternal-september.org
ClassicVB Users Regroup! comp.lang.basic.visual.misc


 
Reply With Quote
 
laingds@canada.com
Guest
Posts: n/a
 
      8th Sep 2011
On Sep 7, 5:48*pm, GS <g...@somewhere.net> wrote:
> lain...@canada.com brought next idea :
>
> > I have a time sheet I want to put directional buttons on similar to a
> > calendar so you can move forward and backward to view different pay
> > periods.
> > Each pay period is 2 weeks long taking up 14 columns + 1 column for
> > NOTES + 1 column for a border, so every pay period is 16 columns wide.
> > Using the Macro Recorder in Excel 2007 it used this;
> > ActiveWindow.ScrollColumn = 21 or 37 or 53 etc. Could I count what
> > column the user is looking at and substitute the number after
> > ActiveWindow.ScrollColumn = with n+ or – 16 ?
> > Is this the best method for moving the focus for a user or can someone
> > suggest something better?

>
> I can see where this isn't going to serve your purpose too well if
> users use the tab key or arrow keys to navigate. Why can't they just
> hold down the 'Alt' key while pressing PageUP (scroll left) or PageDn
> (scroll right)?
>
> --
> Garry
>
> Free usenet access athttp://www.eternal-september.org
> ClassicVB Users Regroup! comp.lang.basic.visual.misc


Different users have different size screens so using Alt PageUP might
work on some screens but not for others. Any thoughts on vb coding
which might work?
 
Reply With Quote
 
Gord
Guest
Posts: n/a
 
      8th Sep 2011
Sub goright()
On Error Resume Next
ActiveCell.Offset(0, 16).Select
End Sub

Sub goleft()
On Error Resume Next
ActiveCell.Offset(0, -16).Select
End Sub


Gord Dibben Microsoft Excel MVP


On Thu, 8 Sep 2011 08:23:49 -0700 (PDT), (E-Mail Removed) wrote:

>On Sep 7, 5:48*pm, GS <g...@somewhere.net> wrote:
>> lain...@canada.com brought next idea :
>>
>> > I have a time sheet I want to put directional buttons on similar to a
>> > calendar so you can move forward and backward to view different pay
>> > periods.
>> > Each pay period is 2 weeks long taking up 14 columns + 1 column for
>> > NOTES + 1 column for a border, so every pay period is 16 columns wide.
>> > Using the Macro Recorder in Excel 2007 it used this;
>> > ActiveWindow.ScrollColumn = 21 or 37 or 53 etc. Could I count what
>> > column the user is looking at and substitute the number after
>> > ActiveWindow.ScrollColumn = with n+ or – 16 ?
>> > Is this the best method for moving the focus for a user or can someone
>> > suggest something better?

>>
>> I can see where this isn't going to serve your purpose too well if
>> users use the tab key or arrow keys to navigate. Why can't they just
>> hold down the 'Alt' key while pressing PageUP (scroll left) or PageDn
>> (scroll right)?
>>
>> --
>> Garry
>>
>> Free usenet access athttp://www.eternal-september.org
>> ClassicVB Users Regroup! comp.lang.basic.visual.misc

>
>Different users have different size screens so using Alt PageUP might
>work on some screens but not for others. Any thoughts on vb coding
>which might work?

 
Reply With Quote
 
GS
Guest
Posts: n/a
 
      8th Sep 2011
(E-Mail Removed) used his keyboard to write :
> On Sep 7, 5:48Â*pm, GS <g...@somewhere.net> wrote:
>> lain...@canada.com brought next idea :
>>
>>> I have a time sheet I want to put directional buttons on similar to a
>>> calendar so you can move forward and backward to view different pay
>>> periods.
>>> Each pay period is 2 weeks long taking up 14 columns + 1 column for
>>> NOTES + 1 column for a border, so every pay period is 16 columns wide.
>>> Using the Macro Recorder in Excel 2007 it used this;
>>> ActiveWindow.ScrollColumn = 21 or 37 or 53 etc. Could I count what
>>> column the user is looking at and substitute the number after
>>> ActiveWindow.ScrollColumn = with n+ or – 16 ?
>>> Is this the best method for moving the focus for a user or can someone
>>> suggest something better?

>>
>> I can see where this isn't going to serve your purpose too well if
>> users use the tab key or arrow keys to navigate. Why can't they just
>> hold down the 'Alt' key while pressing PageUP (scroll left) or PageDn
>> (scroll right)?
>>
>> --
>> Garry
>>
>> Free usenet access athttp://www.eternal-september.org
>> ClassicVB Users Regroup! comp.lang.basic.visual.misc

>
> Different users have different size screens so using Alt PageUP might
> work on some screens but not for others. Any thoughts on vb coding
> which might work?


Well, Alt+[PageUp/PageDn] WILL work on all screens but the scroll would
not necessarily be 16 columns at a time because it will be fixed to
however many columns fit the screen.

Gord offers a VBA solution and I won't give you such a simplistic way
to handle it. I have a project that scrolls 'modules' into view one
module at a time using a combobox. The modules may have any number of
columns each, not necessarily the same number in each. That said, the
code to manage this is fairly complex because it compensates for
wherever the user has navigated by any other means (tab, keyboard).
Each module is assigned a defined name when inserted in the wks, making
it much easier to manage/manipulate views as some modules can be
grouped for display while other modules are hidden (and vice versa).

--
Garry

Free usenet access at http://www.eternal-september.org
ClassicVB Users Regroup! comp.lang.basic.visual.misc


 
Reply With Quote
 
 
 
Reply

Thread Tools
Rate This Thread
Rate This Thread:

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

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


Similar Threads
Thread Thread Starter Forum Replies Last Post
bi-directional 1lane Windows XP General 4 2nd Mar 2007 02:38 AM
Directional Pad Scrolling =?Utf-8?B?UEI=?= Microsoft Dot NET Compact Framework 2 28th Jul 2005 10:19 AM
Bi-directional printing Rover Microsoft Access Form Coding 1 7th Feb 2004 09:55 PM
Bi-directional commumication Peter Roche Microsoft Windows 2000 2 7th Jan 2004 09:28 PM
Re: Directional buttons on Pocket PC device Richard Kucia Microsoft Dot NET Compact Framework 1 11th Aug 2003 06:21 PM


Features
 

Advertising
 

Newsgroups
 


All times are GMT +1. The time now is 02:10 AM.