web
You’re offline. This is a read only version of the page.
close
Skip to main content

Announcements

No record found.

News and Announcements icon
Community site session details

Community site session details

Session Id :
Finance | Project Operations, Human Resources, ...
Suggested Answer

Unhandled script exception: Index 0 of local array is out of range in script 'ASI_Initialize_Explorer_Tree'. Script terminated.

(0) ShareShare
ReportReport
Posted on by

Unhandled script exception:
Index 0 of local array is out of range in script 'ASI_Initialize_Explorer_Tree'. Script terminated.

Looked at previous answers and the insert script they suggested, the table already has that data present.

pastedimage1583168563872v1.png

Categories:
  • Suggested answer
    Derek Albaugh Profile Picture
    Microsoft Employee on at

    What you'll want to do is run these three scripts:

         Select * from ASIEXP81 where ASI_Favorite_Type > 499 and ASI_Favorite_Type < 2000 order by ASI_Favorite_Dict_ID, ASI_Favorite_Type

         Select * from ADH00100 order by ASI_Favorite_Dict_ID, ASI_Favorite_Type

         Select * from ADH00101 order by ASI_Favorite_Dict_ID, ASI_Favorite_Type

    The error you're seeing is usually caused by running the old version of our ClearCompanies script which sees a companyID of 0, which no GP company database will ever have, and removes those records from the ADH00100 and/or ADH00101 tables, which causes the above error when accessing SmartList, and the SmartList reports don't show or work.

    The screenshot you sent appears to be the ADH00100 table, and those three reports are default reports that should have records in the ADH00100 and ADH00101.

    What you should also see in the ADH00100 and ADH00101 tables are records for any custom SmartList reports that are returned by the first script above, which runs against the ASIEXP81 table.

    The ADH00100 table will have one record per custom SmartList report and then the ADH00101 table will have records for each column/field that are in the custom report.

    For example, if the ASIEXP81 returns records for a 0/500 and a 0/501 report, the ADH00100 table should have these two records as well, and the ADH00101 would have at least one record for each report, but more than likely more than that. If they do not, they need to be either manually added or copied from a backup of the DYNAMICS/system database.

    If you need assistance with looking at the script results and/or fixing these tables, open up a support case and we can resolve the issue fairly easily in most cases.

    community.dynamics.com/.../unhandled-script-exception-index-0-of-local-array-is-out-of-range-in-script-39-asi-initialize-explorer-tree-script-terminated

    Thank you,

Under review

Thank you for your reply! To ensure a great experience for everyone, your content is awaiting approval by our Community Managers. Please check back later.

Helpful resources

Quick Links

Season of Sharing Community Challenge Winners!

Congratulations to our community stars!

Women in Power Builds Momentum

Expanding mentorship, skilling, and AI innovation

Congratulations to the August Top 10 Community Leaders

These are the community rock stars!

Leaderboard > Finance | Project Operations, Human Resources, AX, GP, SL

#1
Martin Dráb Profile Picture

Martin Dráb 536 Most Valuable Professional

#2
André Arnaud de Calavon Profile Picture

André Arnaud de Cal... 363 Super User 2026 Season 2

#3
CU-1234529-002 Profile Picture

CU-1234529-002 188

Last 30 days Overall leaderboard

Product updates

Dynamics 365 release plans