Jump to content
Sign in to follow this  
judgedk

Excel - Spreadsheet

Recommended Posts

judgedk

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

Share this post


Link to post
Share on other sites
judgedk

_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?

Share this post


Link to post
Share on other sites
nfaustin

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]

Share this post


Link to post
Share on other sites
judgedk

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 by judgedk

Share this post


Link to post
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
Sign in to follow this  

×

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.