What is the formula to tell you the pathway of the excell file you are currently in?
(i.e. C:\my document\ms office\excel\mikes folder)
I thought the formula was "=Cell()" but it does not work...
please help
What is the formula to tell you the pathway of the excell file you are currently in?
(i.e. C:\my document\ms office\excel\mikes folder)
I thought the formula was "=Cell()" but it does not work...
please help
You can create a function for that...
In the VBE put the following
Function FilePath() as String
FilePath = activeworkbook.path
End Function
And then use that for your formula (however, the code would have to be added to any workbook you were going to use it on)
=cell("filename")
"Maxwell_5000" <[email protected]>
wrote in message
news:[email protected]...
>
> What is the formula to tell you the pathway of the excell file you are
> currently in?
>
> (i.e. C:\my document\ms office\excel\mikes folder)
>
> I thought the formula was "=Cell()" but it does not work...
>
> please help
>
>
> --
> Maxwell_5000
> ------------------------------------------------------------------------
> Maxwell_5000's Profile:
http://www.excelforum.com/member.php...o&userid=23810
> View this thread: http://www.excelforum.com/showthread...hreadid=374638
>
> =cell("filename")
When you use this function, you should always include a cell
reference in the function call:
=CELL("filename",A1)
It doesn't matter what the cell reference is, as long as it is on
the same sheet as the function. The reason is that without the
cell reference, Excel will use the ActiveSheet and ActiveWorkbook
to return the filename, and these may not be the same as the
sheet and workbook containing the formula.
--
Cordially,
Chip Pearson
Microsoft MVP - Excel
Pearson Software Consulting, LLC
www.cpearson.com
"PC" <[email protected]> wrote in message
news:[email protected]...
> =cell("filename")
>
>
> "Maxwell_5000"
> <[email protected]>
> wrote in message
> news:[email protected]...
>>
>> What is the formula to tell you the pathway of the excell file
>> you are
>> currently in?
>>
>> (i.e. C:\my document\ms office\excel\mikes folder)
>>
>> I thought the formula was "=Cell()" but it does not work...
>>
>> please help
>>
>>
>> --
>> Maxwell_5000
>> ------------------------------------------------------------------------
>> Maxwell_5000's Profile:
> http://www.excelforum.com/member.php...o&userid=23810
>> View this thread:
>> http://www.excelforum.com/showthread...hreadid=374638
>>
>
>
There are currently 1 users browsing this thread. (0 members and 1 guests)
Bookmarks