Copy data from a formula driven excel sheet to a New csv using VBA Button

VBA_fanatic

New Member
Joined
Feb 5, 2022
Messages
5
Office Version
  1. 365
Platform
  1. Windows
  2. MacOS
Hi all, I need your help in coding this situation



So, I created a Formulae driven excel workbook consisting of 3 sheets named (Input),(Format), and (transaction entry)

- I want to create a macro with export button that will help me to copy the data from Range A1 to D600 in sheet 3 (transaction entry)

-I want to paste that data from Sheet 3 into a new CSV excel file that is saved in my Downloads folder in my PC



Can you help me to code this?



One of my friend gave me below mentioned code, but It giving error at the bold text below



Application.ScreenUpdating - False

Dim FPath As String, Inventory As Workbook, Transaction Entry As Worksheet

FPath = " Downloads folder"

Workbooks .Open FPath & "Report.csv”

Set Transaction Entry

= ThisWorkbook. Sheets ("Transaction entry")

Set report = Workbooks ("Report.csv")

SUE.Range ("$A$1: $D$600").Copy

Report.Sheets (1) .Range ("Al"). PasteSpecial Paste: =xlPasteValues

stripe. Close SaveChanges:=True
 

Excel Facts

Back into an answer in Excel
Use Data, What-If Analysis, Goal Seek to find the correct input cell value to reach a desired result

Forum statistics

Threads
1,175,792
Messages
5,899,517
Members
434,778
Latest member
Alina N

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Top