get file name inside a macro on Excel

  • Thread starter Get a file name inside a macro
  • Start date
G

Get a file name inside a macro

I need to insert a pause inside a macro, then browse (throught Insert,
Picture, From file) copy the file name, put inside of a variable and resume
the macro.
Any help will be very appreciated.
Thank you
 
B

Bernie Deitrick

Dim FName As String
FName = Application.GetOpenFilename
MsgBox FName

HTH,
Bernie
MS Excel MVP
 
Top