Home |
Search |
Today's Posts |
|
#1
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
Hi there,
I haven't performed any programming for years and I have a memory blank on how to resolve this easy issue. I need to save the current ActiveCell coordinates of the cursor so that I can programmatically jump back to this cell at some later stage. I need the code to save the current cell position and also the code to jump back to this position. I know it involves copying the cell info to variable(s) and using Range to jump but all my attempts have failed :( Thanks James |
#2
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
Sub ActCell()
Dim c c = ActiveCell.Address End Sub Cheers... Mike F "James Duncan" <James wrote in message ... Hi there, I haven't performed any programming for years and I have a memory blank on how to resolve this easy issue. I need to save the current ActiveCell coordinates of the cursor so that I can programmatically jump back to this cell at some later stage. I need the code to save the current cell position and also the code to jump back to this position. I know it involves copying the cell info to variable(s) and using Range to jump but all my attempts have failed :( Thanks James |
#3
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
Hi
first: why are you 'jumping' around at all. Normally no need for select statements in your code For saving try: sub foo() dim oldcell as range dim oldwks as worksheet set oldwks=activesheet set oldcell=activecell 'your code oldwks.activate oldcell.select end sub -- Regards Frank Kabel Frankfurt, Germany "James Duncan" <James schrieb im Newsbeitrag ... Hi there, I haven't performed any programming for years and I have a memory blank on how to resolve this easy issue. I need to save the current ActiveCell coordinates of the cursor so that I can programmatically jump back to this cell at some later stage. I need the code to save the current cell position and also the code to jump back to this position. I know it involves copying the cell info to variable(s) and using Range to jump but all my attempts have failed :( Thanks James |
#4
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
James
one way: Sub SaveAndJump() Dim ACAddress As String MsgBox ActiveCell.Address ACAddress = ActiveCell.Address Range("AC1").Select MsgBox ActiveCell.Address Range(ACAddress).Select MsgBox ActiveCell.Address End Sub Regards Trevor "James Duncan" <James wrote in message ... Hi there, I haven't performed any programming for years and I have a memory blank on how to resolve this easy issue. I need to save the current ActiveCell coordinates of the cursor so that I can programmatically jump back to this cell at some later stage. I need the code to save the current cell position and also the code to jump back to this position. I know it involves copying the cell info to variable(s) and using Range to jump but all my attempts have failed :( Thanks James |
#5
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
A "simplistic" method (I'm simple!).
'Save the row/col values r=activecell.Row c=activecell.Column 'Go back cells(r,c).select -- Regards; Rob ------------------------------------------------------------------------ "James Duncan" <James wrote in message ... Hi there, I haven't performed any programming for years and I have a memory blank on how to resolve this easy issue. I need to save the current ActiveCell coordinates of the cursor so that I can programmatically jump back to this cell at some later stage. I need the code to save the current cell position and also the code to jump back to this position. I know it involves copying the cell info to variable(s) and using Range to jump but all my attempts have failed :( Thanks James |
#6
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
Dim rng as Range
set rng = ActiveCell .. . . Application.Goto rng, true -- Regards, Tom Ogilvy "James Duncan" <James wrote in message ... Hi there, I haven't performed any programming for years and I have a memory blank on how to resolve this easy issue. I need to save the current ActiveCell coordinates of the cursor so that I can programmatically jump back to this cell at some later stage. I need the code to save the current cell position and also the code to jump back to this position. I know it involves copying the cell info to variable(s) and using Range to jump but all my attempts have failed :( Thanks James |
#7
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
James,
Try something like Dim SaveRng As Range Set SaveRng = ActiveCell ' your code here SaveRng.Select -- Cordially, Chip Pearson Microsoft MVP - Excel Pearson Software Consulting, LLC www.cpearson.com "James Duncan" <James wrote in message ... Hi there, I haven't performed any programming for years and I have a memory blank on how to resolve this easy issue. I need to save the current ActiveCell coordinates of the cursor so that I can programmatically jump back to this cell at some later stage. I need the code to save the current cell position and also the code to jump back to this position. I know it involves copying the cell info to variable(s) and using Range to jump but all my attempts have failed :( Thanks James |
Reply |
Thread Tools | Search this Thread |
Display Modes | |
|
|
![]() |
||||
Thread | Forum | |||
coordinates | Charts and Charting in Excel | |||
If activecell.column = variable then activecell,offset (0,1) | Excel Discussion (Misc queries) | |||
map coordinates | Charts and Charting in Excel | |||
Simple way to convert UTM ED50 coordinates to decimal coordinates? | Excel Programming | |||
Converting MouseDown Coordinates to Chart Point Coordinates | Excel Programming |