View Single Post
  #1   Report Post  
Posted to microsoft.public.excel.programming
ErdincEKaracam ErdincEKaracam is offline
external usenet poster
 
Posts: 2
Default How to get the current module name and Sub in VBA?

Dear Sirs,

I want to learn that how to get the current module name and Sub in
VBA?

For example:

In a standard module named as "MPEP" ;

Sub XYZ()
Msgbox "It's an Example"
End Sub

The result should be:
For Module Name: MPEP
and
For Sub Name: XYZ

How we can do this with VBA?

Thanks inadvance.

Erdinç.