Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
jay
 
Posts: n/a
Default How do I count cells beginning with specific letter?

For example: I have a number of cells that contains names, and I have to
count the name that begins with letter "A", what do I do?

many thanks
  #2   Report Post  
JE McGimpsey
 
Posts: n/a
Default

one way:

=COUNTIF(A1:J100,"A*")

In article ,
jay wrote:

For example: I have a number of cells that contains names, and I have to
count the name that begins with letter "A", what do I do?

many thanks

  #4   Report Post  
Posted to microsoft.public.excel.newusers
external usenet poster
 
Posts: 138
Default How do I count cells beginning with specific letter?

I have a nuber of cells that contain names, I have to count the names that
begin with with letter, a,through z, How do I do that?


"jay" wrote:

For example: I have a number of cells that contains names, and I have to
count the name that begins with letter "A", what do I do?

many thanks

  #5   Report Post  
Posted to microsoft.public.excel.newusers
external usenet poster
 
Posts: 35,218
Default How do I count cells beginning with specific letter?

=countif(a1:b99,"a*")



jonathan wrote:

I have a nuber of cells that contain names, I have to count the names that
begin with with letter, a,through z, How do I do that?

"jay" wrote:

For example: I have a number of cells that contains names, and I have to
count the name that begins with letter "A", what do I do?

many thanks


--

Dave Peterson


  #6   Report Post  
Posted to microsoft.public.excel.newusers
external usenet poster
 
Posts: 138
Default How do I count cells beginning with specific letter?

i think you mis understood, i need to know the number of first names in my
data, that begin with each particuliar letter of the alphabet, "A" through "z"

the number of occurances of each letter in the alphabet? A-Z

ex.

a 10
b 9
c 3
d 29


"Dave Peterson" wrote:

=countif(a1:b99,"a*")



jonathan wrote:

I have a nuber of cells that contain names, I have to count the names that
begin with with letter, a,through z, How do I do that?

"jay" wrote:

For example: I have a number of cells that contains names, and I have to
count the name that begins with letter "A", what do I do?

many thanks


--

Dave Peterson

  #7   Report Post  
Posted to microsoft.public.excel.newusers
external usenet poster
 
Posts: 22,906
Default How do I count cells beginning with specific letter?

I think this is a John Walkenbach construct but not positive.

I have altered it return just the first letter of a string.

Sub Count_First_Letters()
Dim letCount(1 To 26) As Long
Dim wkSht As Worksheet
Dim ii As Long
Dim Cell As Range
Dim WrkRng As Range
For Each wkSht In Worksheets
With wkSht
If .Name = "ListLetters" Then
Application.DisplayAlerts = False
Sheets("ListLetters").Delete
End If
End With
Next
Application.DisplayAlerts = True
Set WrkRng = ActiveSheet.UsedRange

For Each Cell In WrkRng
For ii = 1 To 1
If Mid(UCase(Cell), ii, 1) Like "[A-Z]" Then
letCount(Asc(Mid(UCase(Cell), ii, 1)) - 64) = _
letCount(Asc(Mid(UCase(Cell), ii, 1)) - 64) + 1
End If
Next ii
Next Cell
Set CopytoSheet = Worksheets.Add
CopytoSheet.Name = "ListLetters"
CopytoSheet.Activate
Range("B1").Resize(26, 1).Value = Application.Transpose(letCount)
With Range("A1").Resize(26, 1)
.Formula = "=char(row()+64)"
.Value = .Value
End With
End Sub


Gord Dibben MS Excel MVP

On Tue, 14 Oct 2008 20:26:00 -0700, jonathan
wrote:

i think you mis understood, i need to know the number of first names in my
data, that begin with each particuliar letter of the alphabet, "A" through "z"

the number of occurances of each letter in the alphabet? A-Z

ex.

a 10
b 9
c 3
d 29


"Dave Peterson" wrote:

=countif(a1:b99,"a*")



jonathan wrote:

I have a nuber of cells that contain names, I have to count the names that
begin with with letter, a,through z, How do I do that?

"jay" wrote:

For example: I have a number of cells that contains names, and I have to
count the name that begins with letter "A", what do I do?

many thanks


--

Dave Peterson


  #8   Report Post  
Posted to microsoft.public.excel.newusers
external usenet poster
 
Posts: 2,480
Default How do I count cells beginning with specific letter?

Hi Jonathan

Just modify Dave's formula.
Type a, b , c etc down column C, then use

=COUNTIF(A:A,C1&"*")
Copy down through cells C2:C26
--
Regards
Roger Govier

"jonathan" wrote in message
...
i think you mis understood, i need to know the number of first names in my
data, that begin with each particuliar letter of the alphabet, "A" through
"z"

the number of occurances of each letter in the alphabet? A-Z

ex.

a 10
b 9
c 3
d 29


"Dave Peterson" wrote:

=countif(a1:b99,"a*")



jonathan wrote:

I have a nuber of cells that contain names, I have to count the names
that
begin with with letter, a,through z, How do I do that?

"jay" wrote:

For example: I have a number of cells that contains names, and I have
to
count the name that begins with letter "A", what do I do?

many thanks


--

Dave Peterson

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
Count designated cells VB Excel Worksheet Functions 1 August 3rd 05 02:25 AM
Can I count how many grey-filled cells are in a row ? AnthonyG Excel Worksheet Functions 1 February 4th 05 10:08 AM
How do I count shaded cells Randy Excel Worksheet Functions 19 February 3rd 05 11:35 PM
Locate and delete specific cells David Smith Excel Discussion (Misc queries) 1 January 19th 05 04:45 PM
Count non-colored cells Ken G Excel Discussion (Misc queries) 3 January 2nd 05 12:42 PM


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