Macro for quotes

Zanelli

New Member
Joined
Jun 7, 2017
Messages
1
I am working on a Macro (1st time ever) for my quotes. I have it just about how I need it, however, there will be multiple users and I need it to clear multiple sheets and save all sheets to a new Macro Free excel doc, and I need it to Pdf the first sheet only, and print first and second sheets. Also, I need to make sure the original stays original.

Here are the codes I have that work but not quite what I need.

Sub NextQuote()
Range("b18").Value = Range("b18").Value + 1
Range("a20:g48").ClearContents
Range("b8:b17").ClearContents
Range("h8:h18").ClearContents
End Sub


Sub savequotewithnewname()
Dim NewFN As Variant
' Copy Invoice to a new workbook
ActiveSheet.Copy
NewFN = "M:\Quotes & bids\TEST\Quote-" & Range("B9") & "-" & Range("B18").Value & "-" & Format(Now(), "MMDDYYYY") & ".xlsx"
ActiveWorkbook.SaveAs NewFN, FileFormat:=xlOpenXMLWorkbook
ActiveSheet.ExportAsFixedFormat Type:=xlTypePDF, _
Filename:="M:\Quotes & bids\TEST\Quote-" & Range("B9") & "-" & Range("B18").Value & "-" & Format(Now(), "MMDDYYYY") & ".pdf"
ActiveWorkbook.Close
NextQuote
End Sub

Any help you guy can provide would be greatly appreciated.
 

Excel Facts

Best way to learn Power Query?
Read M is for (Data) Monkey book by Ken Puls and Miguel Escobar. It is the complete guide to Power Query.

Forum statistics

Threads
1,216,101
Messages
6,128,841
Members
449,471
Latest member
lachbee

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
Back
Top