Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Toosje
 
Posts: n/a
Default Number of columns ?

I am using

=COLUMN(C:C)-COLUMN(A:A)+1

to calculate the number of the columns A to C (=3).
How can I use replace the C's and A's in the formula, referring to
cell-adresses?

The following formula does not result in 3.

=COLUMN(LEFT(C1,1):LEFT(C1,1))-COLUMN(LEFT(A1,1):LEFT(A1,1))+1

where contents cell C1 = C10 and cell A1 = A10 for example.

Who can help me on this?
  #2   Report Post  
Arvi Laanemets
 
Posts: n/a
Default

Hi

=COLUMN(INDIRECT(C1))-COLUMN(INDIRECT(A1))+1

--
When sending mail, use address arvil<attarkon.ee
Arvi Laanemets


"Toosje" wrote in message
...
I am using

=COLUMN(C:C)-COLUMN(A:A)+1

to calculate the number of the columns A to C (=3).
How can I use replace the C's and A's in the formula, referring to
cell-adresses?

The following formula does not result in 3.

=COLUMN(LEFT(C1,1):LEFT(C1,1))-COLUMN(LEFT(A1,1):LEFT(A1,1))+1

where contents cell C1 = C10 and cell A1 = A10 for example.

Who can help me on this?



  #3   Report Post  
Toosje
 
Posts: n/a
Default

Thanks Arvi, that's the solution!

Toosje

"Arvi Laanemets" schreef:

Hi

=COLUMN(INDIRECT(C1))-COLUMN(INDIRECT(A1))+1

--
When sending mail, use address arvil<attarkon.ee
Arvi Laanemets


"Toosje" wrote in message
...
I am using

=COLUMN(C:C)-COLUMN(A:A)+1

to calculate the number of the columns A to C (=3).
How can I use replace the C's and A's in the formula, referring to
cell-adresses?

The following formula does not result in 3.

=COLUMN(LEFT(C1,1):LEFT(C1,1))-COLUMN(LEFT(A1,1):LEFT(A1,1))+1

where contents cell C1 = C10 and cell A1 = A10 for example.

Who can help me on this?




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
writing the columns a number is listed in David Excel Worksheet Functions 2 March 11th 05 11:18 PM
Is there a maximum number of non-contiguous columns that can be h. Harold Excel Discussion (Misc queries) 6 March 1st 05 09:10 PM
I WANT TO SET PRINT RANGE TO NUMBER OF COLUMNS ckbusia Setting up and Configuration of Excel 2 January 20th 05 07:47 PM
how to increase maximum number of columns in excel 2003 [email protected] Excel Discussion (Misc queries) 1 January 16th 05 08:13 PM
Change number of columns mid page? Bluemax Excel Worksheet Functions 4 November 24th 04 02:11 AM


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