ExcelBanter

ExcelBanter (https://www.excelbanter.com/)
-   Excel Programming (https://www.excelbanter.com/excel-programming/)
-   -   How to get Properties Generate tab Location value (https://www.excelbanter.com/excel-programming/402309-how-get-properties-generate-tab-location-value.html)

[email protected]

How to get Properties Generate tab Location value
 
Hi Reader
How to get Properties Generate tab "Location" value ?
What location is file saved directory.

Below coding just return file name only.
Sub FileName()
Dim xname As String
xname = Application.ActiveWorkbook.Name

xname = Application.InputBox("File Information", "Detail", xname)

End Sub


moonhk

Bob Phillips

How to get Properties Generate tab Location value
 
xPath = Application.ActiveWorkbook.Path


--
---
HTH

Bob


(there's no email, no snail mail, but somewhere should be gmail in my addy)



wrote in message
...
Hi Reader
How to get Properties Generate tab "Location" value ?
What location is file saved directory.

Below coding just return file name only.
Sub FileName()
Dim xname As String
xname = Application.ActiveWorkbook.Name

xname = Application.InputBox("File Information", "Detail", xname)

End Sub


moonhk




moonhk[_2_]

How to get Properties Generate tab Location value
 
On 12$B7n(B6$BF|(B, $B2<8a(B5$B;~(B31$BJ,(B, "Bob Phillips" wrote:
xPath = Application.ActiveWorkbook.Path

--
---
HTH

Bob

(there's no email, no snail mail, but somewhere should be gmail in my addy)

wrote in message

...



Hi Reader
How to get Properties Generate tab "Location" value ?
What location is file saved directory.


Below coding just return file name only.
Sub FileName()
Dim xname As String
xname = Application.ActiveWorkbook.Name


xname = Application.InputBox("File Information", "Detail", xname)


End Sub


moonhk- $Bp,i6Ho0zMQJ8;z(B -


- $Bp}<(Ho0zMQJ8;z(B -



Thank. My coding as below
Sub DisplayPathFileName()
'~~ 2007/12/07
Dim xname As String
Dim xPath As String
If Application.ActiveWorkbook Is Nothing Then
MsgBox "No Open Worksheet", vbCritical
Exit Sub
End If
xname = Application.ActiveWorkbook.Name
xPath = Application.ActiveWorkbook.Path
xname = Application.InputBox("File Information", "Detail", xPath &
"\" & xname)

End Sub


All times are GMT +1. The time now is 11:22 AM.

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