TOROW function not working
If the TOROW function results in an error, it's most likely to be one of these reasons:
#NAME? error
With most Excel functions, a #NAME? error is a clear indication that the function's name is misspelled. With TOROW, it may also mean that the function is not available in your Excel. If your Excel version in other than 365, try using a TOROW alternative.
#NUM error
A #NUM error indicates that the returned array cannot fit into a row. Most often that occurs when you reference entire columns and/or rows instead of a smaller range.
#SPILL error
In most cases, a #SPILL error suggests that the row where you've entered the formula does not have enough blank cells to spill the results into. If the neighboring cells are visually empty, make sure there are no spaces or other non-printing characters in them. For more information, see What #SPILL error means in Excel.