OfficeDev/office-js

Excel Custom Function crashes when given 3 or more parameters

Closed this issue · 4 comments

Provide required information needed to triage your issue

Your Environment

  • Platform [PC desktop, Mac, iOS, Office on the web]: Windows
  • Host [Excel, Word, PowerPoint, etc.]: Excel
  • Office version number: Version 2406 (Build 17716.20002)
  • Operating System: Windows

Expected behavior

  1. Put A1=1, A2=2, A3=3
  2. In cell B1, write =MYFUNC(A1, A2, A3)
  3. The custom function returns a value of 15

Current behavior

Excel crashes as soon as it executes cell B1 (it pauses, then closes, then reopens with no recovery options -- my workbook is gone).

Note that if I had written =MYFUNC(A1, A2), it works fine. The trigger appears to be 3 or more items in my function which accepts any[][][].

Steps to reproduce

  1. Write the custom function
export function myfunc(deps: any[][][]): number {
    console.log(`deps: ${JSON.stringify(deps)}`);
    return 15;
}

Context

I raised issue #4466 which was fixed yesterday. This appears to be a regression caused by that fix.

Thanks @jim22k for helping Microsoft catch this! We have found the root cause and are working on a quick mitigation.
BTW, this is another issue and not related to the fix for #4466 .

Hi @jim22k , this issue has been fixed. Please help check if it is also resolved on your side (need to re-start Excel). Thank you.

@MiaofeiWang Appears to be working now. Thanks for the quick resolution!

Thanks for confirmation. This issue will be closed.