Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 112
Default Algorithm to convert Column Letter to Number

Is there a VBA function or algorithm readily availble that will
convert the column letter designation to the column number (such as is
used in Cells(n, m))??

For example, looing for an F() such that:

m = F("AB")

would return

m = 28


thanks in advance,

Fred Holmes
  #2   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 5,302
Default Algorithm to convert Column Letter to Number

Hi Fred,

Try:

m = Columns("AB").Column

---
Regards,
Norman



"Fred Holmes" wrote in message
...
Is there a VBA function or algorithm readily availble that will
convert the column letter designation to the column number (such as is
used in Cells(n, m))??

For example, looing for an F() such that:

m = F("AB")

would return

m = 28


thanks in advance,

Fred Holmes



  #3   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 2,253
Default Algorithm to convert Column Letter to Number


Columns("AB").Column ?

--
keepITcool
| www.XLsupport.com | keepITcool chello nl | amsterdam


Fred Holmes wrote :

Is there a VBA function or algorithm readily availble that will
convert the column letter designation to the column number (such as is
used in Cells(n, m))??

For example, looing for an F() such that:

m = F("AB")

would return

m = 28


thanks in advance,

Fred Holmes

  #4   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 690
Default Algorithm to convert Column Letter to Number

If A1 held the string "AB", perhaps something like this...

=COLUMN(INDIRECT(A1&"1"))

returns 28
HTH
--
Dana DeLouis
Win XP & Office 2003


"Fred Holmes" wrote in message
...
Is there a VBA function or algorithm readily availble that will
convert the column letter designation to the column number (such as is
used in Cells(n, m))??

For example, looing for an F() such that:

m = F("AB")

would return

m = 28


thanks in advance,

Fred Holmes



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
Column Header - Convert a Number to a letter stickandrock Excel Discussion (Misc queries) 1 June 9th 08 07:54 PM
Convert a letter to a number sross002 Excel Discussion (Misc queries) 2 October 14th 06 02:04 AM
How do I convert a given number into a letter? vortex0001 Excel Worksheet Functions 5 September 8th 05 10:09 AM
column header changed from letter to number, how return to letter Ron Excel Discussion (Misc queries) 2 May 9th 05 08:34 PM


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