Hi,
have following code giving the error 2147024773 (8007007b) and highlighting this line in the code:
complete code:
Another thing happening if disable that line just to save as excel file giving the error 1004 and highlight this line:
thank you
have following code giving the error 2147024773 (8007007b) and highlighting this line in the code:
VBA Code:
ActiveSheet.ExportAsFixedFormat Type:=xlTypePDF, filename:=NewFN, Quality:=xlQualityStandard, IncludeDocProperties:=True, IgnorePrintAreas:=False, OpenAfterPublish:=False
complete code:
VBA Code:
Sub SaveInvoiceBothWaysAndClear()
Dim NewFN As Variant
Call posttoregister
' Create the PDF First
NewFN = "C:\Users\jose.rossi\Desktop\Excel Files\Contras\West Telecom\RHICHOM NETWORKS" & Range("A78").Value & ".pdf"
ActiveSheet.ExportAsFixedFormat Type:=xlTypePDF, filename:=NewFN, Quality:=xlQualityStandard, IncludeDocProperties:=True, IgnorePrintAreas:=False, OpenAfterPublish:=False
'Next, Save the Excel File
ActiveSheet.Copy
NewFN = "C:\Users\jose.rossi\Desktop\Excel Files\Contras\West Telecom\RHICHOM NETWORKS" & Range("A78").Value & ".xlsx"
ActiveWorkbook.SaveAs NewFN, FileFormat:=xlOpenXMLWorkbook
ActiveWorkbook.Close
' Increment the invoice number
Range("K2").Value = Range("K2").Value + 1
' Clear out the invoice fields
Range("C8:C10").ClearContents
Range("A16:K20").ClearContents
End Sub
Another thing happening if disable that line just to save as excel file giving the error 1004 and highlight this line:
VBA Code:
ActiveWorkbook.SaveAs NewFN, FileFormat:=xlOpenXMLWorkbook
thank you