Skip to main content
Community site session details

Community site session details

Session Id : 23PpTf1Rt+GzH7wqdLKe91
Copilot Studio - Topic Creation & Management
Unanswered

Unable to read undefined properties (reading 'getRangeByIndexes')

Like (0) ShareShare
ReportReport
Posted on 12 Sep 2024 06:11:39 by

Hello
My flow consists of converting a .csv file to an excel file .xlsx,
I use the script found at: https://learn.microsoft.com/en-us/office/dev/scripts/resources/samples/convert-csv
But when you try to convert the file, it doesn't work. It throws me the following error:
We couldn't run the script. Try again.
Runtime error: Line 40: Unable to read undefined properties (reading 'getRangeByIndexes')
clientRequestId: fbae89f9-4d72-422c-8871-d5cc00be533e
Do you know how I could solve it?
Thank you
Do you know how I could solve it?
Thank you 
Categories:
  • Suggested answer
    DL-18101455-0 Profile Picture
    2 on 18 Oct 2024 at 15:10:22
    Unable to read undefined properties (reading 'getRangeByIndexes')
    Hello,
     
    I got the same issue and I found out that the script applies on the sheet "Sheet1" (first line of the function : let sheet = workbook.getWorksheet("Sheet1");)
     
    Check if your template file has one sheet with this name. As I use a French version of Excel, the default sheet is called "Feuil1". So I changed the value in the script to match and it worked.
     
    Hope this will helps you.
     
    Regards

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

Announcing our 2025 Season 2 Super Users!

A new season of Super Users has arrived, and we are so grateful for…

Paul Stork – Community Spotlight

We are honored to recognize Paul Stork as our July 2025 Community…

Congratulations to the June Top 10 Community Leaders!

These are the community rock stars!

Leaderboard > Copilot Studio

#1
Michael E. Gernaey Profile Picture

Michael E. Gernaey 169 Super User 2025 Season 2

#2
Romain The Low-Code Bearded Bear Profile Picture

Romain The Low-Code... 150

#3
sandeep_angara Profile Picture

sandeep_angara 75 Super User 2025 Season 2

Featured topics

Loading complete