View Single Post
  #13   Report Post  
Posted to microsoft.public.excel.worksheet.functions
Gord Dibben Gord Dibben is offline
external usenet poster
 
Posts: 22,906
Default General Excel question

=COUNTA(C8:J8) counts multiple entries in a cell as one.

Also......I would change If Target.Column = 3 Then to

If Not Application.Intersect(Target, Columns("C:H")) Is Nothing Then

Nothing wrong with your revision except it potentially includes columns past
H


Gord


On Thu, 18 Jun 2009 16:05:50 GMT, "dolpandotcom via OfficeKB.com"
<u52610@uwe wrote:

Hi Gord,

Thanks a million. It is working fine. Since I needed it to work on 6 other
columns, I decided to make the If Target.Column = 3 Then to be IF Target.
Column=3 which makes it to include other columns that I want to use, but I
will like two or three items selected in a cell to be counted as one using
the COUNT(C8:j8) as an example.

Is there any other statement to add to the COUNTI(C8:j8) to enable count two
or more items selected in a cell as one (1) please?

Thanks.
Dolpan

Gord Dibben wrote:
The code you posted is from the "SameCell" sheet in Debra's sample workbook.

Are you sure you pasted it into the appropriate sheet module in your
workbook?

This code is event code and is "lunched"(sic) only when a selection is made
from a dropdown list in column C

If your dropdown is not in column C you must edit this line to your column
number

If Target.Column = 3 Then

Gord

Hi Gord,

[quoted text clipped - 73 lines]
Dolpandotcom
06/16/09