how to get full Part name in code

Hi guys can anyone fix the bug in the code.

I want the full name of the model

.....................................................

    Dim excRange As range

    Dim excSheet As Excel.Worksheet

    Set excSheet = excApp.ActiveSheet

    Set excRange = excSheet.range(excApp.Cells(1, 1), excApp.Cells(1000, 1))

   

    Dim searchRes As range

    Dim name As String

    Dim index As Integer

    Dim title As String

   

    title = swModel.GetTitle()

    index = InStr(title, ".")

    name = Left(title, Len(title) - IIf(index = 0, 0, index + 1))

    Set searchRes = excRange.Cells.Find(name)

SolidworksApi macros