1 min readfrom Microsoft Excel | Help & Support with your Formula, Macro, and VBA problems | A Reddit Community

Use UDF output in another UDF.

I have a User Defined Function (UDF) called, funnily enough, "SumColoredCells(G3:G336)" which works fine. Because I am adding rows to the spreadsheet, the 336th row will increase, so I wrote another UDF called "LastRow()" to find the last used row. I would like to use LastRow() as part of the range in my SumColoredCells() UDF but if I use SumColoredCells(G3:LastRow()) I get a #VALUE! error. I have tried different things (convert to string, etc) but have not been successful.

This is not a major problem because the spreadsheet is personal and trivial but I am learning to use UDFs just to keep my brain active and challenged. This one is doing my head in.

submitted by /u/oil-filter
[link] [comments]

Want to read more?

Check out the full article on the original site

View original article

Tagged with

#machine learning in spreadsheet applications
#rows.com
#modern spreadsheet innovations
#enterprise-level spreadsheet solutions
#digital transformation in spreadsheet software
#row zero
#collaborative spreadsheet tools
#AI-driven spreadsheet solutions
#cloud-based spreadsheet applications
#automation in spreadsheet workflows
#no-code spreadsheet solutions
#Excel compatibility
#Excel alternatives for data analysis
#User Defined Function
#SumColoredCells
#LastRow
#spreadsheet
#range
#UDFs
##VALUE!