cancel
Showing results for 
Search instead for 
Did you mean: 

Facing an issue in Move Worksheet - MS Excel VBO

Hi team,

I'm facing the below error while trying to copy a worksheet from one workbook to another workbook. I'm using the latest MS Excel VBO from DX.

7325.png

7326.png

I'm passing True in Copy flag since the action name says Move Worksheet but also has a flag exposed to only copy(should rename this action to Move/Copy Worksheet)

I have both workbooks opened.

Tried different scenarios here but could not find a solution to this error. 

Any help would be appreciated.



------------------------------
If I was of assistance, please vote for it to be the "Best Answer".

Thanks & Regards,
Tejaskumar Darji
Sr. Consultant-Technical Lead
------------------------------
1 BEST ANSWER

Best Answers

Mukeshh_k
MVP

Additionally I did try with the most latest version I could find out from DX with download link as : https://digitalexchange.blueprism.com/dx/entry/3439/solution/ms-excel-vbo, and I was able to move the worksheet with this VBO as well.

You should pass the Destination Position as 1 as index starts from 1 in MS Excel (Ref - Sheet1 by default), let me know if you face the error again !! with these changes.

7313.png

7314.png

7316.png



------------------------------
Kindly up vote this as "Best Answer" if it adds value or resolves your query in anyway possible, happy to help.

Regards,

Mukesh Kumar - Senior Automation Developer

NHS England, United Kingdom, GB
------------------------------
Regards,

Mukesh Kumar

View answer in original post

3 REPLIES 3

Mukeshh_k
MVP

Hello @Tejaskumar_Darji - I have tried replicating that with one of my extended actions in MS Excel VBO Extended object - I was able to move sheet at said index from source Excel workbook to the primary Excel workbook.

I have attached the release alongside for object just check if you can see and compare with your own MS Excel VBO, let me know if you face any difficulties in executing it.

7305.png

7306.png

7307.png7308.png



------------------------------
Kindly up vote this as "Best Answer" if it adds value or resolves your query in anyway possible, happy to help.

Regards,

Mukesh Kumar - Senior Automation Developer

NHS England, United Kingdom, GB
------------------------------
Regards,

Mukesh Kumar

Mukeshh_k
MVP

Additionally I did try with the most latest version I could find out from DX with download link as : https://digitalexchange.blueprism.com/dx/entry/3439/solution/ms-excel-vbo, and I was able to move the worksheet with this VBO as well.

You should pass the Destination Position as 1 as index starts from 1 in MS Excel (Ref - Sheet1 by default), let me know if you face the error again !! with these changes.

7313.png

7314.png

7316.png



------------------------------
Kindly up vote this as "Best Answer" if it adds value or resolves your query in anyway possible, happy to help.

Regards,

Mukesh Kumar - Senior Automation Developer

NHS England, United Kingdom, GB
------------------------------
Regards,

Mukesh Kumar

It got finally resolved. The issue was with the way I was opening the other PDF. I was creating 2 separate handles and opening both excel individually before doing copy worksheet but after seeing your snapshot I directly opened another workbook in the same handle. Now able to copy worksheets.

Thanks @Mukesh Kumar 



------------------------------
If I was of assistance, please vote for it to be the "Best Answer".

Thanks & Regards,
Tejaskumar Darji
Sr. Consultant-Technical Lead
------------------------------