There is a way to get the VB Project Module your Sub is in, if you use a variable (or constant) to save your Sub name.
See the code below:
Option Explicit Sub mySub() Const PROC_NAME = "mySub" Dim VBProj As VBIDE.VBProject Dim VBComp As VBIDE.VBComponent Dim CodeMod As VBIDE.CodeModule Dim i As Long Dim ModuleName As String Set VBProj = ActiveWorkbook.VBProject ' loop through all modules, worksheets and other objects in VB Project For Each VBComp In VBProj.VBComponents Set CodeMod = VBComp.CodeModule ' loop through all code line inside current module For i = 1 To CodeMod.CountOfLines If Len(CodeMod.Lines(i, 1)) > 0 Then ' if the name of current sub is found within the current code line If InStr(CodeMod.Lines(i, 1), PROC_NAME) > 0 Then ModuleName = CodeMod.Name '<-- get the current Module name MsgBox "Sub " & PROC_NAME & " found in " & ModuleName & " module" Exit Sub End If End If Next i Next VBComp End Sub
In order to access the VB Project Module, you need to follow the 2 steps below:
Step 1: Add "Trust access to the VBA project object model" , go to Developer >> Macro Security >> then add a V to the Trust access to the VBA project object model.

Step 2: Add Reference to your VB project, add "Microsoft Visual Basic for Applications Extensibility 5.3"

That's it, you are ready to give it a go !