Project 2 - Create a report using PowerQuery, Macro VBA, List Functions and Data Validation functions for Data Reporting of Supply Chain Management companies
PDF FORM APPLICATION DATA CODE
Sub savepdf()
Dim ThisRng As Range
Dim strfile As String
Dim myfile As Variant
If Selection.Count = 1 Then
Set ThisRng = Application.InputBox("Select a range", "Get Range", Type:=8)
Else
Set ThisRng = Selection
End If
strfile = "Selection" & " ." & Format(Now(), "yyyymmdd_hhmmss") & ".pdf"
strfile = ThisWorkbook.Path & "\" & strfile
myfile = Application.GetSaveAsFilename(InitialFileName:=strfile, FileFilter:="PDF Files (*.pdf), *.pdf", Title:="Select Folder and File Name to Save as PDF")
If myfile <> "False" Then
ThisRng.ExportAsFixedFormat Type:=xlTypePDF, Filename:=myfile, Quality:=xlQualityStandard, IncludeDocProperties:=True, IgnorePrintAreas:=False, OpenAfterPublish:=True
Else
MsgBox "No File Selected. PDF will not be saved", vbOKOnly, "No File Selected"
End If
End Sub
SPELLING CHECK CODE
Public Sub spellingcheck()
Dim cell As Range
For Each cell In ActiveSheet.UsedRange
If Not Application.CheckSpelling(word:=cell.Text) Then
cell.Style = "Bad"
End If
Next cell
End Sub
https://drive.google.com/file/d/1yqGjCgZML3_eZvpK2iWmNQW69N2Sd2q6/view?usp=share_link
https://drive.google.com/file/d/1yqGjCgZML3_eZvpK2iWmNQW69N2Sd2q6/view?usp=share_link