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

When they said...
When they said you are going to "Excel at life", they meant you "will be doing Excel your whole life".

Forum statistics

Threads
1,223,893
Messages
6,175,241
Members
452,622
Latest member
Laura_PinksBTHFT

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