Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 4
Default How to set ActiveCell to a new column?


I want to set the activecell to the same row it currently is and set
the column to "B". The activecell can be in any column. I looked
into using "offset", but it would take a bit more (calcing if a
negative or positive offset) than I would suspect. Is there something
like "Set Activecell.Column = "B""?

How do the pros do it?

Carl

  #2   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 111
Default How to set ActiveCell to a new column?

Hi,
try this....

Range("B"&Activecell.Row).Select

Hth
OJ

  #3   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 27,285
Default How to set ActiveCell to a new column?

cells(activeCell.row,2).Select

--
Regards,
Tom Ogilvy


"Carl" wrote in message
...

I want to set the activecell to the same row it currently is and set
the column to "B". The activecell can be in any column. I looked
into using "offset", but it would take a bit more (calcing if a
negative or positive offset) than I would suspect. Is there something
like "Set Activecell.Column = "B""?

How do the pros do it?

Carl



  #4   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 4
Default How to set ActiveCell to a new column?

Thanks. Works as desired.

Carl

On 17 Mar 2005 01:12:21 -0800, "OJ" wrote:

Hi,
try this....

Range("B"&Activecell.Row).Select

Hth
OJ


  #5   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 4
Default How to set ActiveCell to a new column?

Thanks. Works as desired. I can see from previous poster there are
several ways to code a line (AKA - skin a cat).

Carl


On Thu, 17 Mar 2005 08:07:48 -0500, "Tom Ogilvy"
wrote:

cells(activeCell.row,2).Select




  #6   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 27,285
Default How to set ActiveCell to a new column?

some approaches are more robust than others. for example, cells can take a
number variable in both arguments

i = cells(activecell.Row,256).End(xltoLeft) + 1
cells(activecell.Row, i) = "Something"

would put something in the next available column of the row of the
activeCell

as an example.

--
Regards,
Tom Ogilvy

"Carl" wrote in message
...
Thanks. Works as desired. I can see from previous poster there are
several ways to code a line (AKA - skin a cat).

Carl


On Thu, 17 Mar 2005 08:07:48 -0500, "Tom Ogilvy"
wrote:

cells(activeCell.row,2).Select




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 ActiveCell at the first column of the same row... Dave Excel Discussion (Misc queries) 2 April 16th 09 08:03 PM
If activecell.column = variable then activecell,offset (0,1) Battykoda via OfficeKB.com Excel Discussion (Misc queries) 1 October 2nd 07 08:05 PM
activecell.specialcells(xlCellTypeVisible) returns column refe noel Excel Programming 1 January 4th 05 04:33 PM
Find ActiveCell.column LindaMac Excel Programming 4 November 10th 04 05:48 PM
Activecell.FormulaR1C1 Versus ActiveSheet.cells(column, row) Ashish Shridharan Excel Programming 2 February 15th 04 04:46 PM


All times are GMT +1. The time now is 09:22 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"