LinkBack Thread Tools Search this Thread Display Modes
Prev Previous Post   Next Post Next
  #3   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 27,285
Default Find ActiveCell.column

That would be the hard way to do it


Dim lColumn as long
Dim sValue as string

lColumn = activecell.column
sValue = worksheets("sheet1").Cells(1, lColumn + 1).value


or

sValue = Worksheets("sheet1").Cells(1,ActiveCell.Column).Va lue

--
Regards,
Tom Ogilvy


"LindaMac" wrote in message
...
When I use the Activecell.column statement it returns a numeric value for

the
column(ex: 27), I want the character value (ex: AA).

Here is a sample of my code, I always want to access row #1, but the

column
will vary based on the activecell location:

Dim sColumn as string
Dim sRangeName as string
Dim sValue as string

sColumn = activecell.column
sRangeName = sColumn + "1"
sValue = worksheets("sheet1").range(sRangeName).value





 
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
How To Find If The ActiveCell Is Protected FARAZ QURESHI Excel Discussion (Misc queries) 7 April 13th 09 05: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.FormulaR1C1 Versus ActiveSheet.cells(column, row) Ashish Shridharan Excel Programming 2 February 15th 04 04:46 PM
Use of Selection.Find & ActiveCell Steve Slechta[_2_] Excel Programming 4 November 19th 03 02:07 PM


All times are GMT +1. The time now is 04:11 AM.

Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
Copyright ©2004-2025 ExcelBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Excel"