+ Reply to Thread
Results 1 to 8 of 8

Can you use two array constants in a formula?

  1. #1
    Registered User
    Join Date
    08-10-2022
    Location
    London
    MS-Off Ver
    365
    Posts
    27

    Can you use two array constants in a formula?

    Hi Everyone

    I'm having trouble with putting two array constants in a formula. Not sure if you can use array constants in one formula or if i should try something else, Sumproduct maybe?

    Anyway, in my attached example i want to count number of 1,2,3's in the number column and any of those numbers that have either a/c in the letter column.
    Attached Files Attached Files

  2. #2
    Forum Guru
    Join Date
    09-10-2017
    Location
    Chippenham, England
    MS-Off Ver
    365
    Posts
    15,080

    Re: Can you use two array constants in a formula?

    Yes you can use two arrays, but one has to be vertical & the other horizontal, like
    Formula: copy to clipboard
    Please Login or Register  to view this content.

  3. #3
    Registered User
    Join Date
    08-10-2022
    Location
    London
    MS-Off Ver
    365
    Posts
    27

    Re: Can you use two array constants in a formula?

    Thanks but what do you mean by vertical and horizontal?

    The only difference i can see here is use of a semi colon?

  4. #4
    Forum Guru
    Join Date
    09-10-2017
    Location
    Chippenham, England
    MS-Off Ver
    365
    Posts
    15,080

    Re: Can you use two array constants in a formula?

    The semi-colon is a row separator & the commas is a column separator. If you remove the sum at the start the formula will spill in 2 directions like
    Excel 365 (Windows) 32 bit
    D
    E
    F
    2
    1
    0
    0
    3
    0
    0
    1
    Sheet: Sheet1

    Where the 1st row is counting the "a" & the 2nd is counting "c"

  5. #5
    Registered User
    Join Date
    08-10-2022
    Location
    London
    MS-Off Ver
    365
    Posts
    27

    Re: Can you use two array constants in a formula?

    Ahh ok i think i get it.

    Just to be clear, in your example
    Where the 1st row is counting the "D" & the 2nd is counting "F"

    That's what's happening right?
    Thank you for your quick replies, much appreciated.

  6. #6
    Forum Guru
    Join Date
    09-10-2017
    Location
    Chippenham, England
    MS-Off Ver
    365
    Posts
    15,080

    Re: Can you use two array constants in a formula?

    No the row in red is counting the number of "a"s for 1, 2 & 3, whilst the row in blue is counting the number of "c"s

    Count
    1
    2
    3
    a
    1
    0
    0
    c
    0
    0
    1

  7. #7
    Registered User
    Join Date
    08-10-2022
    Location
    London
    MS-Off Ver
    365
    Posts
    27

    Re: Can you use two array constants in a formula?

    Ah right ok, i get it now.

    Thank you very much for your help.

  8. #8
    Forum Guru
    Join Date
    09-10-2017
    Location
    Chippenham, England
    MS-Off Ver
    365
    Posts
    15,080

    Re: Can you use two array constants in a formula?

    You're welcome & thanks for the feedback.

+ Reply to Thread

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Similar Threads

  1. How to enter array constants correctly
    By RaulSerg in forum Excel Formulas & Functions
    Replies: 3
    Last Post: 11-18-2021, 04:40 PM
  2. Concatenate Single Cell Array Constants
    By excelformulae in forum Excel Programming / VBA / Macros
    Replies: 1
    Last Post: 11-14-2019, 03:11 AM
  3. [SOLVED] Array constants
    By czlowiek121 in forum Excel Formulas & Functions
    Replies: 3
    Last Post: 12-18-2018, 08:43 AM
  4. Array constants in a nested VLOOKUP
    By soneaf in forum Excel Formulas & Functions
    Replies: 4
    Last Post: 02-03-2016, 01:00 PM
  5. Dynamic array constants
    By michalrosa in forum Excel Formulas & Functions
    Replies: 3
    Last Post: 07-02-2010, 04:01 AM
  6. Converting weeknumber formula to VBA (array constants)
    By opopanax666 in forum Excel Programming / VBA / Macros
    Replies: 4
    Last Post: 03-14-2008, 06:23 PM
  7. Formula Array Constants, Problem
    By pegbol in forum Excel Formulas & Functions
    Replies: 4
    Last Post: 03-01-2005, 02:45 PM

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts

Search Engine Friendly URLs by vBSEO 3.6.0 RC 1