Hello everyone, I need some assistance with some VBA code I'm working on.

Some background on this:
The below code works fine, so long as you DO select any number of photos above zero when the filepicker dialog pops up. If you hit Cancel, or the "X" button, it then gives 'Run-Time Error '13': Type Mismatch'.

I have tried several Exit functions for the Application.GetOpenFileName, none have so far worked, I keep getting the Type Mismatch error.
I DO understand I am missing a cancel checker argument, as stated, I have tried several, but they have all failed, so I am posting the code without one of those tests, in hopes someone can tell me what I'm doing wrong here.
Because at this point, I have no idea where to put a cancel button arguement checker, and I need some help!

Again, the code works for what I want it to do, and I can't use any MSO, or FileDialogs, I have to use the OpenFileName as a workaround for various reasons, but I need it to not result in an ERROR if Cancel is or "X" is clicked.

Private Sub CommandButton1_Click()
'Custom Photos Button
Dim WB As Workbook
Dim WS As Worksheet
Dim RG As Range

Set WB = ThisWorkbook
Set WS = Sheets("DATAI")
Set RG = WS.Range("F10")

WS.Range("G1:G8").Value = ""
WS.Range("F13").Value = "Custom"

'Photo Select Dialog
    fpathArray = Application.GetOpenFilename(FileFilter:="All Files,*.*", Title:="Select file", multiSelect:=True)

    For i = 1 To UBound(fpathArray)
    Next i

'Output Stored Photo FilePaths in Array to Data Sheet
    WS.Range("G1:G" & UBound(fpathArray)) = Application.Transpose(fpathArray)

'Imports selected photos
Call Test2

RG.Value = "X"
Unload Me
Test.Show

End Sub