Home |
Search |
Today's Posts |
#1
Posted to microsoft.public.excel.misc
|
|||
|
|||
Cell references in VBA?
How do I find out which cell I've selected?
I have a VBA routine that selects a (one-cell) named range, which will likely move around due to row/column insertions and deletions. How can I get VBA to know what actual cell it's in? |
#2
Posted to microsoft.public.excel.misc
|
|||
|
|||
Cell references in VBA?
Activecell is the active cell of a selection, so if the selection is one
cell, it is also the selection. You can work with that Msgbox Activecell.Value or get properties of it Msgbox Activecell.Address -- HTH Bob Phillips (remove nothere from email address if mailing direct) "GoBobbyGo" wrote in message ... How do I find out which cell I've selected? I have a VBA routine that selects a (one-cell) named range, which will likely move around due to row/column insertions and deletions. How can I get VBA to know what actual cell it's in? |
#3
Posted to microsoft.public.excel.misc
|
|||
|
|||
Cell references in VBA?
Any easy way to get the X and Y coords of the cell? -- MartinShort Software Tester ------------------------------------------------------------------------ MartinShort's Profile: http://www.excelforum.com/member.php...o&userid=22034 View this thread: http://www.excelforum.com/showthread...hreadid=494191 |
#4
Posted to microsoft.public.excel.misc
|
|||
|
|||
Cell references in VBA?
You can get it relative to the spreadsheet with Activecell.Left and .Top.
-- HTH Bob Phillips (remove nothere from email address if mailing direct) "MartinShort" wrote in message ... Any easy way to get the X and Y coords of the cell? -- MartinShort Software Tester ------------------------------------------------------------------------ MartinShort's Profile: http://www.excelforum.com/member.php...o&userid=22034 View this thread: http://www.excelforum.com/showthread...hreadid=494191 |
#5
Posted to microsoft.public.excel.misc
|
|||
|
|||
Cell references in VBA?
Cheers Bob -- MartinShort Software Tester ------------------------------------------------------------------------ MartinShort's Profile: http://www.excelforum.com/member.php...o&userid=22034 View this thread: http://www.excelforum.com/showthread...hreadid=494191 |
Reply |
Thread Tools | Search this Thread |
Display Modes | |
|
|
Similar Threads | ||||
Thread | Forum | |||
Excel insits that I use absolute cell references | Excel Discussion (Misc queries) | |||
Fixed cell references | Excel Discussion (Misc queries) | |||
How to use complex no. functions that have cell references? | Excel Worksheet Functions | |||
Cell references change when entering new data | New Users to Excel | |||
Absolute cell references and subsequent problems. | Excel Discussion (Misc queries) |