ExcelBanter

ExcelBanter (https://www.excelbanter.com/)
-   Excel Programming (https://www.excelbanter.com/excel-programming/)
-   -   how to add column with the workbook-filename (https://www.excelbanter.com/excel-programming/350309-how-add-column-workbook-filename.html)

juergenkemeter[_12_]

how to add column with the workbook-filename
 

Hi,
how can I add a column 'filename', which displays the workbook name in
it, using VBA?

cheers
juergen


--
juergenkemeter
------------------------------------------------------------------------
juergenkemeter's Profile: http://www.excelforum.com/member.php...o&userid=25248
View this thread: http://www.excelforum.com/showthread...hreadid=500954


Tom Ogilvy

how to add column with the workbook-filename
 
Public Function ShowName()
Application.Volatile
ShowName = ThisWorkbook.Name
End Function

or use ThisWorkbook.FullName

Then in a cell

=ShowName()

--
Regards,
Tom Ogilvy


"juergenkemeter"
wrote in
message news:juergenkemeter.21jzna_1137122407.212@excelfor um-nospam.com...

Hi,
how can I add a column 'filename', which displays the workbook name in
it, using VBA?

cheers
juergen


--
juergenkemeter
------------------------------------------------------------------------
juergenkemeter's Profile:

http://www.excelforum.com/member.php...o&userid=25248
View this thread: http://www.excelforum.com/showthread...hreadid=500954




juergenkemeter[_13_]

how to add column with the workbook-filename
 

thanks!
Jürgen


--
juergenkemeter
------------------------------------------------------------------------
juergenkemeter's Profile: http://www.excelforum.com/member.php...o&userid=25248
View this thread: http://www.excelforum.com/showthread...hreadid=500954



All times are GMT +1. The time now is 12:14 PM.

Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
ExcelBanter.com