Karicula Posted September 15, 2010 Share Posted September 15, 2010 I need to be able to copy an excel range without reading the data into an array - when I use the array it does not bring over the date data in the correct format and it converts it to "2.01E+13" which isn't all that helpful. I am downloading the original data from a website that creates the file in TXT format and then converting it to an .xls Any ideas on how to approach this issue would be appreciated!Data Copier To Post.au3 Link to comment Share on other sites More sharing options...
Karicula Posted September 15, 2010 Author Share Posted September 15, 2010 This is the code: ; Set up the variables #include <Excel.au3> #include <Array.au3> #include <Constants.au3> #Include <string.au3> #Region Variable declarations Global $sXlsMasterFile = "C:\1data\SLD_Data_Master.xls" Global $DLFile = "C:\1data\Tester.xls" #EndRegion #Region new code $oExcel = ObjCreate("Excel.Application") $oExcel.Visible = 2 $oExcel.WorkBooks.Open($sXlsMasterFile) $oExcel.WorkBooks.Open($DLFile) $oExcel.Application.ActiveSheet.Range("A2:BB16").select $oExcel.Application.ActiveSheet.Range("A2:BB16").copy ;$oExcel.WorkBooks.Visible($sXlsMasterFile) tried this ;$oExcel.WorkBooks.($sXlsMasterFile).Select tried this $oExcel.WorkBooks.Select($sXlsMasterFile) ; tried this $oExcel.Application.ActiveSheet.Range("A2:BB16").select $oExcel.Application.ActiveSheet.Range("A2:BB16").paste #EndRegion Link to comment Share on other sites More sharing options...
seandisanti Posted September 19, 2010 Share Posted September 19, 2010 Couple of solutions here that might work 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