How to Fix Relative References in Excel Named LAMBDA Functions
Question details
A LAMBDA formula returns incorrect results when saved as a named function due to shifting relative references.

- Product
- Spreadsheets
- Device & OS
- not provided
- Scenario
- Creating a named LAMBDA function in the Name Manager for repeated use across a worksheet.
- Observed behavior
- The LAMBDA function works correctly when typed directly into a cell, but outputs incorrect references or errors after being stored in the Name Manager.
Ensure you know exactly which ranges in your LAMBDA formula need to shift dynamically based on the input, and which source ranges must remain strictly fixed across your entire workbook.
Lock Source Ranges Using Absolute References
Prevent source ranges from shifting by locking them with absolute references before saving the LAMBDA function in the Name Manager.
When defining a named formula, the Name Manager evaluates relative references based on the currently active cell. If you call the function from a different cell, the relative reference shifts accordingly, leading to incorrect calculations.
Navigate to the Formulas tab on the ribbon menu and click on Name Manager.
Locate and select the LAMBDA function causing the issue, then click the Edit button to modify its reference formula.
Change the static range references to absolute references by adding dollar signs. For example, change '3 times'!K3:CL3 to '3 times'!$K$3:$CL$3. You can also highlight the range in the formula bar and press the F4 key to toggle reference types quickly.
Click OK to save the changes, close the Name Manager, and test the custom named function in a new cell to ensure it pulls data from the correct fixed range.

Optimize the FILTER Function Inside LAMBDA
Simplify your LAMBDA formula by utilizing the built-in empty value argument of the FILTER function instead of a broader IFERROR wrapper.
Manage Advanced Formulas and Names Easily in WPS Spreadsheets
You can seamlessly create, edit, and manage custom named LAMBDA functions with WPS Spreadsheets, offering a highly compatible and intuitive Name Manager for complex array formulas.
- 1. Download and Install: Download WPS Office Free and open your existing spreadsheet containing the custom formulas.
- 2. Access the Name Manager: Navigate to the Formulas tab on the top ribbon and click on Name Manager.
- 3. Edit the LAMBDA Formula: Select your named LAMBDA function, click Edit, and easily insert absolute references (e.g., $K$3:$CL$3).
- 4. Apply and Calculate: Click OK to save your changes. Your custom LAMBDA function is now ready to be used anywhere in the workbook without shifting references.

Frequently Asked Questions
Why do relative references change when saved in the Name Manager?
When you define a named formula using relative references, the Name Manager evaluates the range relative to the cell that was active at the time of creation. If you call the function from a different cell later, the reference shifts accordingly, which often leads to incorrect calculations.
How can I quickly convert relative references to absolute references?
While editing your formula in the Name Manager or formula bar, highlight the cell range you want to lock and press the F4 key on your keyboard. This will automatically insert the dollar signs ($) needed to create an absolute reference.
Is there a difference between TOCOL and TRANSPOSE in a LAMBDA function?
Yes. TOCOL transforms any array or range into a single column, regardless of its original shape or dimensions. TRANSPOSE simply flips the orientation of an array, converting rows to columns and vice versa. Depending on your data layout, TOCOL is generally safer for forcing a one-dimensional vertical array.




