judgedk Posted February 6, 2009 Share Posted February 6, 2009 Hi, been trying to get my head around this but it dosent seem to work. I'm using the Excel UDF. when the script starts i allready have a excel spreadsheet open. how do i get that spreadsheet that is allready open to have this name : " $oExcel1 " within the script, so i can work with it? i need to copy all the data from the 1st spreadsheet that is allready open into a new spreadsheet, then sort the data and so on.. but i guess that is no problem.. if i only could find out how to handle the spreadsheet that is allready open and wasent created by me. Regards Roy Link to comment Share on other sites More sharing options...
Zedna Posted February 6, 2009 Share Posted February 6, 2009 _ExcelBookAttach() Resources UDF ResourcesEx UDF AutoIt Forum Search Link to comment Share on other sites More sharing options...
judgedk Posted February 6, 2009 Author Share Posted February 6, 2009 _ExcelBookAttach()Thank you so much Link to comment Share on other sites More sharing options...
judgedk Posted February 7, 2009 Author Share Posted February 7, 2009 _ExcelBookAttach() Been playing around with that func but cant seem to get i work.. "$oExcel = _ExcelBookAttach( "Microsoft Excel" , "Title" );with $s_mode = "Title" ==> Name of the open workbook _ExcelWriteCell($oExcel, "If you can read this, then Success!", 1, 1);Write to the Cell"; I only know a part of the title like "Microsoft Excel" but when this runs its the only spreadsheet open. when i run this i get this error --> Warning from function _ExcelAttach, No Match what am i doing wrong? Link to comment Share on other sites More sharing options...
nfaustin Posted February 7, 2009 Share Posted February 7, 2009 I think the "Microsoft Excel" should be a complete title. Try AutoIt window info tool to view the Complete title of that spreadsheet. [font="Palatino Linotype"][size="2"]*** The information contained in this post should be considered and certified WORKS ON MY MACHINE ***[/size][/font][font="Palatino Linotype"][size="2"] [/size][/font] Link to comment Share on other sites More sharing options...
judgedk Posted February 7, 2009 Author Share Posted February 7, 2009 (edited) I think the "Microsoft Excel" should be a complete title.Try AutoIt window info tool to view the Complete title of that spreadsheet.Is that the only way ? cause when this run's i don't know the complete string..well i guess i could use the "WinGettitle" command to get to full title but anyway. Edited February 7, 2009 by judgedk Link to comment Share on other sites More sharing options...
Zedna Posted February 8, 2009 Share Posted February 8, 2009 Look at Opt("WinTitleMatchMode", 2) ;1=start, 2=subStr, 3=exact, 4=advanced, -1 to -4=Nocase Resources UDF ResourcesEx UDF AutoIt Forum Search 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