Project 2 - Create a report using PowerQuery, Macro VBA, List Functions and Data Validation functions for Data Reporting of Supply Chain Management companies
3 question answer-
Create VBA Code to convert selected data into pdf from applicant data
-
Sub PrintSelectionToPDF()Dim ThisRng As RangeDim strfile As StringDim myfile As VariantIf Selection.Count = 1 ThenSet ThisRng = Application.InputBox("Select a range", "Get Range", Type:=8)ElseSet ThisRng = SelectionEnd If'Prompt for save locationstrfile = "Selection" & "_" _& Format(Now(), "yyyymmdd_hhmmss") _& ".pdf"strfile = ThisWorkbook.Path & "\" & strfilemyfile = Application.GetSaveAsFilename _(InitialFileName:=strfile, _FileFilter:="PDF Files (*.pdf), *.pdf", _Title:="Select Folder and File Name to Save as PDF")If myfile <> "False" Then 'save as PDFThisRng.ExportAsFixedFormat Type:=xlTypePDF, Filename:= _myfile, Quality:=xlQualityStandard, IncludeDocProperties:=True, _IgnorePrintAreas:=False, OpenAfterPublish:=TrueElseMsgBox "No File Selected. PDF will not be saved", vbOKOnly, "No File Selected"End IfEnd Sub
answer
Check Spelling mistakes in the workbook using VBA Code
-
Public Sub HighlightSpellingMistakes()
Dim wd As Range
For Each wd In ActiveSheet.UsedRange
If Not Application.CheckSpelling(word:=wd.Text) Then
wd.Font.Color = vbRed
wd.Interior.Color = vbYellow
End If
Next wd
End Sub
i have attached in 1 question & 2question link excel and flag document excel as attached
https://docs.google.com/spreadsheets/d/1jrYZtUp7At3aQDS5AdwRuv52uxJGqqMI/edit?usp=share_link&ouid=116658163060738436094&rtpof=true&sd=true