SOLVED

New Contributor

# Excel formula

How to get excel to create a series of numbers based on 2 given numbers, for example if you enter 5 in one cell and 10 in another cell so that it can create numbers from 5 to 10, or for example 100 in one cell and 500 in another cell so that it create numbers from 100 to 500?

7 Replies

# Re: Excel formula

Example with 10 and 50

Formula in A2:

``=SEQUENCE(B1-A1+1,,A1)``

# Re: Excel formula

Thanks for the quick answer but it didn't work, it says that there are a formula issues

# Re: Excel formula

What version (2013, 2016...365) of Excel do you run? If 2021 or 365 what is the exact error message you get?

# Re: Excel formula

Hi, it is 365

It says that there are an issues hvid this formula....

"Are you trying to write a formula?

When the first sign in a equal sign (=) or a (-), the excel think it is a formula:

* If you write =1+1, it shows 2 in the celle

You can solve it by writting a (") as a first sign"

best response confirmed by Sergei Baklan (MVP)
Solution

# Re: Excel formula

I suspect your formula separator (based on your Regional settings) is not the comma but something else, i.e. ; in which case the formula would be:

``=SEQUENCE(B1-A1+1;;A1)``

Open the attached file, Excel will figure it out...

# Re: Excel formula

Hi
1000 thanks, now it works.

# Re: Excel formula

Glad I could help. Nice day...