Forum Discussion
Generating an Formula using concatenation in excel
- Sep 25, 2023
This uses the XLM command EVALUATE within Name Manager where it works correctly just as HansVogelaar 's solution. With 365 the process can be taken a step further and the name can be a Lambda function.
EVALUATEλ = LAMBDA(formula, EVALUATE(formula))
The sole advantage is that EVALUATEλ can be reused with multiple strings.
HansVogelaar Thanks for the Input Hans… I tried adding =Evaluate(formula) but it didn’t work because excel doesn’t have the evaluate function. Is there any way that I can give you the sample excel for this formula or somewhere we can talk about it?
It does have the EVALUATE function since that pre-dates the introduction of VBA to Office. However, it does not run on a standard worksheet, hence the way it is wrapped within a Name using Name Manager. It may work on a Macro sheet but that is outside my area of knowledge.
- AjayGujaySep 26, 2023Copper ContributorThanks for putting your valuable time on this Peter I will check the work around provided and get back to you in a Private message as well.
- HansVogelaarSep 26, 2023MVP
See the attached workbook. It uses PeterBartholomew1's elegant Lambda wrapper of EVALUATE.
Save the workbook to a Trusted Location for Excel. It is now a .xlsm workbook since the use of EVALUATE requires it.
- AjayGujaySep 26, 2023Copper Contributor
Do I need to enable anything for this formula to work I see it says #BLOCKED