Jump to content

Excel to Array Script Broken with upgrade from 3.3.8.1 to 3.3.12.0


CCMgmt
 Share

Recommended Posts

Why am I getting an error = 5, extended = -274XXXXXX when I run this script?  My original script worked fine with 3.3.8.1

CODE FROM 3.3.8.1 Working script before Upgrade

[

$sFilePath1 = "C:UsersrootDocumentsTuan_Menu_Prog_RV6.xlsm"

Func ReadArray()
Local $oExcel = "$sFilePath1"
Local $oExcel = _ExcelBookOpen($sFilePath1,0 ,True) ;Open Excel book Read Only, make it Hidden
;Msgbox(0,"@ErrorOpen", @error, 8)
$aArray = _ExcelReadSheetToArray($oExcel, 8, 1, 680 ,39 , False) ;Starting on the 8tht Row, 1st Column, Row Count 10, Column Count 38,
;Msgbox(0,"@ErrorRead", @error, 8)
;Msgbox(0,"@Extended", @error, 8)
;_ArrayDisplay($aArray, "Starting on the 2nd Column")
_ExcelBookClose($oExcel) ; And finally we close out
$Rows = UBound($aArray)
MsgBox(4096, "Spreadsheet Status:", "Spreadsheet Read into System. Click OK to continue with database programing.")

]

Since upgrade I can't get the script to read to array. Please See attached Script that Errors out.

Trying to repair this small bit of code.

Thank you in advance for any help.

Tres!ItemPrograming_RV10_.au3

Link to comment
Share on other sites

The Excel UDF haxs been rewritten.

Please have a look at the script breaking changes in the changelog.

A link there leads to details about the changes to the Excel UDF.

More information can be found in the wiki.

My UDFs and Tutorials:

Spoiler

UDFs:
Active Directory (NEW 2022-02-19 - Version 1.6.1.0) - Download - General Help & Support - Example Scripts - Wiki
ExcelChart (2017-07-21 - Version 0.4.0.1) - Download - General Help & Support - Example Scripts
OutlookEX (2021-11-16 - Version 1.7.0.0) - Download - General Help & Support - Example Scripts - Wiki
OutlookEX_GUI (2021-04-13 - Version 1.4.0.0) - Download
Outlook Tools (2019-07-22 - Version 0.6.0.0) - Download - General Help & Support - Wiki
PowerPoint (2021-08-31 - Version 1.5.0.0) - Download - General Help & Support - Example Scripts - Wiki
Task Scheduler (NEW 2022-07-28 - Version 1.6.0.1) - Download - General Help & Support - Wiki

Standard UDFs:
Excel - Example Scripts - Wiki
Word - Wiki

Tutorials:
ADO - Wiki
WebDriver - Wiki

 

Link to comment
Share on other sites

a temporary fix until you are able to re-write your scripts would be to download an older version of AutoIt and copy the old Excel UDF into your Include folder so that you can still use the old functions.

:alien:

If @error Then
    MsgBox(262192, "", @ComputerName & " slaps " & @UserName & " around a bit with a large trout!")
EndIf

"Yeah yeah yeah patience, how long will that take?"  -Ed Gruberman

REAL search results  |  SciTE4AutoIt3 Editor Full Version

Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
 Share

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...