Derby Trail Forums

Go Back   Derby Trail Forums > Esoteric Central
Register FAQ Members List Calendar Today's Posts

Reply
 
Thread Tools Display Modes
  #1  
Old 01-16-2008, 06:00 PM
Scav Scav is offline
Saratoga
 
Join Date: May 2006
Location: Northwest of The Chi
Posts: 16,012
Default Excel Question

This might be pretty extreme but I am trying to put together something and I need some help with formula writing.

Lets say that Cell A1 has the value of "1,3,5,6"

I want to create a formula where A2 will equal 4, for the number of values within that cell....Any help with this would be great.
Reply With Quote
  #2  
Old 01-16-2008, 06:26 PM
SentToStud's Avatar
SentToStud SentToStud is offline
Arlington Park
 
Join Date: May 2006
Posts: 4,065
Default

use spaces, not commas. also enter the four numbers into the cell like this:

'1 3 5 6

then try this:
=IF(LEN(TRIM(A1))=0,0,LEN(TRIM(A1))-LEN(SUBSTITUTE(A1," ",""))+1)
Reply With Quote
  #3  
Old 01-16-2008, 06:32 PM
TheSpyder's Avatar
TheSpyder TheSpyder is offline
Del Mar
 
Join Date: Jun 2006
Location: Nothing could be finer
Posts: 5,127
Default

=Count(1,3,5,6)

You have to rewrite the numbers. Maybe someone knows another way
__________________
Don't sweat the petty things and don't pet the sweaty things.
Reply With Quote
  #4  
Old 01-16-2008, 06:42 PM
SentToStud's Avatar
SentToStud SentToStud is offline
Arlington Park
 
Join Date: May 2006
Posts: 4,065
Default

Quote:
Originally Posted by SentToStud
use spaces, not commas. also enter the four numbers into the cell like this:

'1 3 5 6

then try this:
=IF(LEN(TRIM(A1))=0,0,LEN(TRIM(A1))-LEN(SUBSTITUTE(A1," ",""))+1)
Scav, it should work with commas in the cell also.
Reply With Quote
  #5  
Old 01-16-2008, 06:46 PM
Scav Scav is offline
Saratoga
 
Join Date: May 2006
Location: Northwest of The Chi
Posts: 16,012
Default

Bruce's way works but it is some serious formulas....Gonna have to lock the cell so people don't mess with it. It is for P6 writing, for all to use when formulating tickets.

FYI Bruce,it works without that ' in front of the numbers, I appreciate it
Reply With Quote
  #6  
Old 01-16-2008, 06:50 PM
Scav Scav is offline
Saratoga
 
Join Date: May 2006
Location: Northwest of The Chi
Posts: 16,012
Default

BRUCE>>>>>>

It works. Can't wait to reveal this for all at DT...I hope it will allow me to post the file for people...
Reply With Quote
  #7  
Old 01-17-2008, 08:56 PM
pgardn
 
Posts: n/a
Default

I loves excel.

Can do so much stuff with it.
Loaded with little presents if
you use it a lot.
Reply With Quote
Reply



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Forum Jump


All times are GMT -5. The time now is 08:40 AM.


Powered by vBulletin® Version 3.6.8
Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.