tempman Posted January 16, 2013 Share Posted January 16, 2013 #include <Excel.au3> #include <Array.au3> $sFilePath1 = @ScriptDir & "\ipligence-lite.xlsx" Local $oExcel = _ExcelBookOpen($sFilePath1, 0) $aArray = $oExcel.Activesheet.Range("A1:A170241").Value _ArrayDisplay($aArray) _ExcelBookClose($oExcel, 0, 0) Exit array is display in coloms and i want to display it in rows Link to comment Share on other sites More sharing options...
water Posted January 16, 2013 Share Posted January 16, 2013 Haven't tested it but I think the array is to large to use the Excel transpose function: $aArrayTransposed = $oExcel.Transpose($aArray) If it crashes you have to manually create the new array. My UDFs and Tutorials: Spoiler UDFs:Active Directory (NEW 2022-02-19 - Version 1.6.1.0) - Download - General Help & Support - Example Scripts - WikiExcelChart (2017-07-21 - Version 0.4.0.1) - Download - General Help & Support - Example ScriptsOutlookEX (2021-11-16 - Version 1.7.0.0) - Download - General Help & Support - Example Scripts - WikiOutlookEX_GUI (2021-04-13 - Version 1.4.0.0) - DownloadOutlook Tools (2019-07-22 - Version 0.6.0.0) - Download - General Help & Support - WikiPowerPoint (2021-08-31 - Version 1.5.0.0) - Download - General Help & Support - Example Scripts - WikiTask Scheduler (NEW 2022-07-28 - Version 1.6.0.1) - Download - General Help & Support - Wiki Standard UDFs:Excel - Example Scripts - WikiWord - Wiki Tutorials:ADO - WikiWebDriver - Wiki Link to comment Share on other sites More sharing options...
tempman Posted January 16, 2013 Author Share Posted January 16, 2013 since I am 67 posts memeber you need to show me where to put that line? Link to comment Share on other sites More sharing options...
jdelaney Posted January 16, 2013 Share Posted January 16, 2013 (edited) maybe: _ArrayDisplay(Const ByRef $avArray [, $sTitle = "Array: ListView Display" [, $iItemLimit = -1 [, $iTranspose = 0 [, $sSeparator = "" [, $sReplace = "|" [, $sHeader = ""]]]]]])But who cares how the array is displayed, what are you attempting to do with the data: that's where the logic of the script comes into playIf you want to actually take the data of the column, and transpose to the rows, you will cutt off some of your data...there are not that many columns avaialbe in excel 2010 Edited January 16, 2013 by jdelaney IEbyXPATH-Grab IE DOM objects by XPATH IEscriptRecord-Makings of an IE script recorder ExcelFromXML-Create Excel docs without excel installed GetAllWindowControls-Output all control data on a given window. Link to comment Share on other sites More sharing options...
water Posted January 16, 2013 Share Posted January 16, 2013 After line: $aArray = $oExcel.Activesheet.Range("A1:A170241").Value My UDFs and Tutorials: Spoiler UDFs:Active Directory (NEW 2022-02-19 - Version 1.6.1.0) - Download - General Help & Support - Example Scripts - WikiExcelChart (2017-07-21 - Version 0.4.0.1) - Download - General Help & Support - Example ScriptsOutlookEX (2021-11-16 - Version 1.7.0.0) - Download - General Help & Support - Example Scripts - WikiOutlookEX_GUI (2021-04-13 - Version 1.4.0.0) - DownloadOutlook Tools (2019-07-22 - Version 0.6.0.0) - Download - General Help & Support - WikiPowerPoint (2021-08-31 - Version 1.5.0.0) - Download - General Help & Support - Example Scripts - WikiTask Scheduler (NEW 2022-07-28 - Version 1.6.0.1) - Download - General Help & Support - Wiki Standard UDFs:Excel - Example Scripts - WikiWord - Wiki Tutorials:ADO - WikiWebDriver - Wiki Link to comment Share on other sites More sharing options...
tempman Posted January 16, 2013 Author Share Posted January 16, 2013 #include <Excel.au3> #include <Array.au3> $sFilePath1 = @ScriptDir & "\ipligence-lite.xlsx" Local $oExcel = _ExcelBookOpen($sFilePath1, 0) $aArray = $oExcel.Activesheet.Range("A1:A170241").Value $aArrayTransposed = $oExcel.Transpose($aArray) _ArrayDisplay($aArrayTransposed) _ExcelBookClose($oExcel, 0, 0) Exit >Running:(3.3.8.1):C:\Program Files\AutoIt3\autoit3.exe "D:\z.au3" --> Press Ctrl+Alt+F5 to Restart or Ctrl+Break to Stop D:\z.au3 (8) : ==> The requested action with this object has failed.: $aArrayTransposed = $oExcel.Transpose($aArray) $aArrayTransposed = $oExcel.Transpose($aArray)^ ERROR ->20:04:39 AutoIT3.exe ended.rc:1 >Exit code: 1 Time: 5.025 Link to comment Share on other sites More sharing options...
water Posted January 16, 2013 Share Posted January 16, 2013 Looks like the array is too large for Excel. In this case you either need to transpose the table yourself. Or if you just need to process the table then process rows as columns and columns as rows. My UDFs and Tutorials: Spoiler UDFs:Active Directory (NEW 2022-02-19 - Version 1.6.1.0) - Download - General Help & Support - Example Scripts - WikiExcelChart (2017-07-21 - Version 0.4.0.1) - Download - General Help & Support - Example ScriptsOutlookEX (2021-11-16 - Version 1.7.0.0) - Download - General Help & Support - Example Scripts - WikiOutlookEX_GUI (2021-04-13 - Version 1.4.0.0) - DownloadOutlook Tools (2019-07-22 - Version 0.6.0.0) - Download - General Help & Support - WikiPowerPoint (2021-08-31 - Version 1.5.0.0) - Download - General Help & Support - Example Scripts - WikiTask Scheduler (NEW 2022-07-28 - Version 1.6.0.1) - Download - General Help & Support - Wiki Standard UDFs:Excel - Example Scripts - WikiWord - Wiki Tutorials:ADO - WikiWebDriver - Wiki Link to comment Share on other sites More sharing options...
Recommended Posts
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 accountSign in
Already have an account? Sign in here.
Sign In Now