Toggling navigating between 3 cells?

S

StargateFan

Rather than make various different buttons on my toolbar, it would be
much easier for users to press one button and toggle navigating to 2
specific and going back to A2 at last toggle. Can this be done?

i.e., from startpoint (whatever it is) go to D2
from D2 to G2 and then each time pressing navigation goes backwards:
G2 to D2
D2 to A2

Thanks! :eek:D
 
D

Don Guillett

Rather than make various different buttons on my toolbar, it would be
much easier for users to press one button and toggle navigating to 2
specific and going back to A2 at last toggle.  Can this be done?

i.e., from startpoint (whatever it is) go to D2
from D2 to G2 and then each time pressing navigation goes backwards:
G2 to D2
D2 to A2

Thanks!  :eek:D

Do you just want to goto these cells or is it fair to assume that you
want to make an entry in each?? Still confusing.
"If desired, send your file to dguillett @gmail.com I will only look
if:
1. You send a copy of this message on an inserted sheet
2. You give me the newsgroup and the subject line
3. You send a clear explanation of what you want
4. You send before/after examples and expected results."
 
G

GS

After serious thinking StargateFan wrote :
Rather than make various different buttons on my toolbar, it would be
much easier for users to press one button and toggle navigating to 2
specific and going back to A2 at last toggle. Can this be done?

i.e., from startpoint (whatever it is) go to D2
from D2 to G2 and then each time pressing navigation goes backwards:
G2 to D2
D2 to A2

Thanks! :eek:D

In the code behind the button, use a static var to monitor which cell
location the user is currently at. Each time the button is clicked,
advance the stored value.

So then...
1st click: set var to 1 (var=0 after startup)
2nd click: check var and set to next position (2 in this case)
3rd click: check var and set to next position (3 in this case)
4th click: check var and set to next position (1 in this case)

Optionally, you could use a global var instead of a local static var.
 
G

GS

GS used his keyboard to write :
In this case, you might want to reset the var...

1st click: set var to next position (1 in this case)
2nd click: check var and set to next position (2a in this case)
3rd click: check var and set to next position (3 in this case)
4th click: check var and set to next position (2b in this case)
5th click: check var and set to next position (1 in this case)

...so that when the var is '2a' you know to activate the 3rd cell in the
sequence next. When it's '2b' you know which dir it's going and so the
cycle repeats.

HTH
 
S

StargateFan

Do you just want to goto these cells or is it fair to assume that you
want to make an entry in each?? Still confusing.

Oh, yes. User will need to enter data into cells after navigating to.
Honestly, though, I had no idea it would be this tough.

I've gone back to re-assess and re-wrote things. By a very strange
coincidence, the cells are evenly spaced apart. So I hope it's okay
and didn't mean to cause a ruckus <g>, but have decided to not go into
something that may still be beyond me to do. Using variables and
storing data reminds me of the headaches I've had in writing simple
databases. So thought I'd save the headaches all around.

Ultimately, "ActiveCell.Offset(0, -3).Select" and
"ActiveCell.Offset(0, 3).Select" work perfectly fine in my toolbar.
And FaceIDs have 2 great buttons of 155 and 156 so that works well.
And it does the job.

Thanks everyone. Appreciate the help.

******************

p.s., before closing this issue, I have a question. When I first went
on Office 2007 (which I hate, btw ... sorry), I was told all the
floating toolbars on our spreadsheets would never work. And they
don't. There was _some_ help for the static custom toolbars but the
results are grossly inadequate.

Will there ever be a way to get back complete functionality with our
older Office files? The ribbon doesn't come even close to what my
custom toolbars do and the floating toolbars just can't be beat in the
files that I have them on. Thx. Just curious if any strides have
been made to bridge the new with the more efficient (to me) old.
 
G

GS

StargateFan explained :
Oh, yes. User will need to enter data into cells after navigating to.
Honestly, though, I had no idea it would be this tough.

I've gone back to re-assess and re-wrote things. By a very strange
coincidence, the cells are evenly spaced apart. So I hope it's okay
and didn't mean to cause a ruckus <g>, but have decided to not go into
something that may still be beyond me to do. Using variables and
storing data reminds me of the headaches I've had in writing simple
databases. So thought I'd save the headaches all around.

Ultimately, "ActiveCell.Offset(0, -3).Select" and
"ActiveCell.Offset(0, 3).Select" work perfectly fine in my toolbar.
And FaceIDs have 2 great buttons of 155 and 156 so that works well.
And it does the job.

Thanks everyone. Appreciate the help.

******************

p.s., before closing this issue, I have a question. When I first went
on Office 2007 (which I hate, btw ... sorry), I was told all the
floating toolbars on our spreadsheets would never work. And they
don't. There was _some_ help for the static custom toolbars but the
results are grossly inadequate.

Will there ever be a way to get back complete functionality with our
older Office files? The ribbon doesn't come even close to what my
custom toolbars do and the floating toolbars just can't be beat in the
files that I have them on. Thx. Just curious if any strides have
been made to bridge the new with the more efficient (to me) old.

Toolbars "created" in earlier projects will appear on the Addins tab of
the ribbon. You can't 'float' them because they're not dockable like in
earlier versions. Closest you can get is to make the toolbar a popup
menu that appears when cells of appropriate context are right-clicked.
 

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