Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • Home
  • SEARCH
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 42117
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 10, 20262026-05-10T15:17:16+00:00 2026-05-10T15:17:16+00:00

I have an excel spreadsheet in a format similar to the following… | NAME

  • 0

I have an excel spreadsheet in a format similar to the following…

| NAME  | CLUB | STATUS | SCORE | | Fred  |  a   | Gent   | 145   | | Bert  |  a   | Gent   | 150   | | Harry |  a   | Gent   | 195   | | Jim   |  a   | Gent   | 150   | | Clare |  a   | Lady   | 99    | | Simon |  a   | Junior | 130   | | John  |  b   | Junior | 130   |    :    : | Henry |  z   | Gent   | 200   | 

I need to convert this table into a list of the ‘Top Ten’ teams. The rules are

  • Each team score is taken from the sum of four members of that club.
  • These totals should be of the best four scores except…
    • Each team must consist of at least one Junior or Lady

For example in the table above the team score for club A would be 625 not 640 as you would take the scores for Harry(190), Bert(150), Jim(150), and Simon(130). You could not take Fred’s(145) score as that would give you only Gents.

My question is, can this be done easily as a series of Excel formula, or will I need to resort to using something more procedural?

Ideally the solution needs to be automatic in the team selections, I don’t want to have to create separate hand crafted formula for each team. I also will not necessarily have a neatly ordered list of each clubs members. Although I could probably generate the list via an extra calculation sheet.

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. 2026-05-10T15:17:16+00:00Added an answer on May 10, 2026 at 3:17 pm
    Public Function TopTen(Club As String, Scores As Range)      Dim i As Long     Dim vaScores As Variant     Dim bLady As Boolean     Dim lCnt As Long     Dim lTotal As Long      vaScores = FilterOnClub(Scores.Value, Club)     vaScores = SortOnScore(vaScores)      For i = LBound(vaScores, 2) To UBound(vaScores, 2)         If lCnt = 3 And Not bLady Then             If vaScores(3, i) <> 'Gent' Then                 lTotal = lTotal + vaScores(4, i)                 bLady = True                 lCnt = lCnt + 1             End If         Else             lTotal = lTotal + vaScores(4, i)             lCnt = lCnt + 1             If vaScores(3, i) <> 'Gent' Then bLady = True         End If          If lCnt = 4 Then Exit For     Next i      TopTen = lTotal  End Function  Private Function FilterOnClub(vaScores As Variant, sClub As String) As Variant      Dim i As Long, j As Long     Dim aTemp() As Variant      For i = LBound(vaScores, 1) To UBound(vaScores, 1)         If vaScores(i, 2) = sClub Then             j = j + 1             ReDim Preserve aTemp(1 To 4, 1 To j)             aTemp(1, j) = vaScores(i, 1)             aTemp(2, j) = vaScores(i, 2)             aTemp(3, j) = vaScores(i, 3)             aTemp(4, j) = vaScores(i, 4)         End If     Next i      FilterOnClub = aTemp  End Function  Private Function SortOnScore(vaScores As Variant) As Variant      Dim i As Long, j As Long, k As Long     Dim aTemp(1 To 4) As Variant      For i = 1 To UBound(vaScores, 2) - 1         For j = i To UBound(vaScores, 2)             If vaScores(4, i) < vaScores(4, j) Then                 For k = 1 To 4                     aTemp(k) = vaScores(k, j)                     vaScores(k, j) = vaScores(k, i)                     vaScores(k, i) = aTemp(k)                 Next k             End If         Next j     Next i      SortOnScore = vaScores  End Function 

    Use as =TopTen(H2,$B$2:$E$30) where H2 contains the club letter.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Ask A Question

Stats

  • Questions 65k
  • Answers 65k
  • Best Answers 0
  • User 1
  • Popular
  • Answers
  • Editorial Team

    How to approach applying for a job at a company ...

    • 7 Answers
  • Editorial Team

    How to handle personal stress caused by utterly incompetent and ...

    • 5 Answers
  • Editorial Team

    What is a programmer’s life like?

    • 5 Answers
  • added an answer In case of PHP they go to upload_tmp_dir or system… May 11, 2026 at 11:19 am
  • added an answer How many instances of the ModuleAttribute class do you have… May 11, 2026 at 11:19 am
  • added an answer I've never done this before, but you could use the… May 11, 2026 at 11:19 am

Related Questions

I have an excel spreadsheet in a format similar to the following... | NAME
I have an Excel spreadsheet with a few thousand entries in it. I want
I have an Excel Spreadsheet like this id | data for id | more
I have an Excel spreadsheet with 1 column, 700 rows. I care about every
I have an Excel spreadsheet containing a list of strings. Each string is made
I have an Excel spreadsheet of data like: ColumnA ColumnB 33 11 25 5
I have an Excel application in which I want to present the user with
I have an excel file which has more than 65536 rows. However, I can
I have an Excel 2003 workbook that contains a macro to copy certain of
I have an Excel worksheet with an image (logo). If I right-click on the

Trending Tags

analytics british company computer developers django employee employer english facebook french google interview javascript language life php programmer programs salary

Top Members

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.