Skip to main content
Best answer

Duplicating Excel workbook and then add or update row

  • February 19, 2022
  • 6 replies
  • 453 views

Forum|alt.badge.img

I am so close to getting this Zap to work but it’s failing at the end. I’ll explain the concept, how I’m attempting to solve, and what the error is.

 

Requirement: When trigger hits (Monday.com) create a copy of an existing spreadsheet and then add data to the new spreadsheet.

 

My Attempt:

  • Trigger - Monday.com action
  • Action 1 - OneDrive,  Find File
  • Action 2 - OneDrive, Upload file- Upload a copy of the file from Action 1
  • Action 3 - Excel - Add or Update Row - Use the file uploaded in Action 2 and update/add

Error - In action 3 I come across errors. After I select the Spreadsheet it attempts to access that spreadsheet to retrieve the worksheets but errors out. I receive different errors depending on the value I insert for the Spreadsheet field, none seem to work. See screenshots below

 

 

 

Best answer by SamBBest answer by SamB

Hey @FrankP,

It looks as though a “File Object” from OneDrive has been selected instead of selecting an existing spreadsheet from the dropdown, which is why the Zap isn’t able to see any worksheets in it: 
120abdbc7a67db4c9eab5ec8f0b59312.png

Excel is expecting either an existing Excel spreadsheet to be selected from the dropdown menu (or to have the ID number for the spreadsheet to be supplied as a Custom value).  

If step 3 (action 2) in your Zap is uploading a copy of the file from step 2 (action 1) then you’d need to use a “Find Spreadsheet” type of action to get the correct ID for the spreadsheet. The issue here is that there isn’t a “Find Spreadsheet” action currently available for Excel so you’d need to select the spreadsheet from the dropdown menu. Which likely isn’t going to work for your desired workflow here.

I’ve gone ahead and added your vote to an existing feature request to have a “Find Spreadsheet/Worksheet” action added to the Microsoft Excel integration. I can’t make any promises as to when it will be added but we’ll be sure to email you as soon as it is. 

In the meantime, depending on what information you’re looking to update the new Excel spreadsheets with you might be able to set up a second Zap that triggers when a New Spreadsheet is added in Excel. This should give the ID number for the spreadsheet which you could then use in an Add Row or Update Row action to update it. 

Hope that helps! :slight_smile:

View original
Did this topic help you find an answer to your question?
This post has been closed for comments. Please create a new post if you need help or have a question about this topic.

6 replies

Troy Tessalone
Forum|alt.badge.img+14
  • Zapier Expert
  • 30919 replies
  • February 19, 2022

Hi @FrankP 

Check out this related article for GSheets that may be helpful:

 


Forum|alt.badge.img
  • Author
  • Beginner
  • 10 replies
  • February 19, 2022
Troy Tessalone wrote:

Hi @FrankP 

Check out this related article for GSheets that may be helpful:

https://community.zapier.com/featured-articles-65/how-to-dynamically-set-google-sheet-and-worksheet-custom-values-4346

 

Thank you for sharing but this is for Google sheets and outlines for different items, i’m not seeing where I could use for this scenario.

Thanks, Frank


Troy Tessalone
Forum|alt.badge.img+14
  • Zapier Expert
  • 30919 replies
  • February 19, 2022

@FrankP

Concept is the same as described in the related article.

The trick is to work backwards, select static options for the Spreadsheet and Worksheet fields, to configure the Zap, then replace with dynamic variables, and test.

 


SamB
Community Manager
Forum|alt.badge.img+11
  • Community Manager
  • 7457 replies
  • Answer
  • February 21, 2022

Hey @FrankP,

It looks as though a “File Object” from OneDrive has been selected instead of selecting an existing spreadsheet from the dropdown, which is why the Zap isn’t able to see any worksheets in it: 
120abdbc7a67db4c9eab5ec8f0b59312.png

Excel is expecting either an existing Excel spreadsheet to be selected from the dropdown menu (or to have the ID number for the spreadsheet to be supplied as a Custom value).  

If step 3 (action 2) in your Zap is uploading a copy of the file from step 2 (action 1) then you’d need to use a “Find Spreadsheet” type of action to get the correct ID for the spreadsheet. The issue here is that there isn’t a “Find Spreadsheet” action currently available for Excel so you’d need to select the spreadsheet from the dropdown menu. Which likely isn’t going to work for your desired workflow here.

I’ve gone ahead and added your vote to an existing feature request to have a “Find Spreadsheet/Worksheet” action added to the Microsoft Excel integration. I can’t make any promises as to when it will be added but we’ll be sure to email you as soon as it is. 

In the meantime, depending on what information you’re looking to update the new Excel spreadsheets with you might be able to set up a second Zap that triggers when a New Spreadsheet is added in Excel. This should give the ID number for the spreadsheet which you could then use in an Add Row or Update Row action to update it. 

Hope that helps! :slight_smile:


Forum|alt.badge.img
  • Author
  • Beginner
  • 10 replies
  • March 1, 2022
Troy Tessalone wrote:

@FrankP

Concept is the same as described in the related article.

The trick is to work backwards, select static options for the Spreadsheet and Worksheet fields, to configure the Zap, then replace with dynamic variables, and test.

 

Thanks Troy! I ended up using a method similar to this and got it to work. Since it’s unable to be tested in Zapier you sort of need to take a leap of faith and trust that the system will find the file that’s going to be created. 


christina.d
Forum|alt.badge.img+9
  • Zapier Staff
  • 2653 replies
  • March 2, 2022

Thanks for coming back around to update the thread on your solution, @FrankP