Home | Contact Us | FAQ | Search & Site Map | Link to Us
Sign In | Join | Other 45 Sites in Network
Home
Discussion GroupsFormsForms ProgrammingQueriesModules / DAO / VBAReports / PrintingMacrosDatabase DesignSecurityConversionImporting / LinkingSQL Server / ADPMultiuser / NetworkingReplicationSetup / ConfigurationDeveloper ToolkitsActiveX ControlsNew UsersGeneral 1General 2
Access DirectoryToolsTutorialsUser Groups
Related Topics
SQL ServerOther DB ProductsMS OfficeMore Topics ...

MS Access Forum / Macros / March 2007

Tip: Looking for answers? Try searching our database.

OutputTo Action

Thread view: 
Enable EMail Alerts  Start New Thread
Thread rating: 
Frank - 30 Mar 2007 23:12 GMT
I am using the OutputTo action in one of my macros. I have the Output File
argument hard coded to a folder on my C drive. Is there a way to have that
output file defualt to the current folder without hardcoding the entire path?
Sort of like using the App.path in a visual basic solution.

Thanks for any advice.

Frank
Douglas J. Steele - 31 Mar 2007 01:57 GMT
If you just put a file name (no folder), it should be written to the current
folder. Problem is, you can never be sure what the current folder is (it's
seldom the same folder where the MDB file exists).

Assuming you're using Access 2000 or newer, try using

  CurrentProject.Path & "\MyFile.txt"

Signature

Doug Steele, Microsoft Access MVP
http://I.Am/DougSteele
(no private e-mails, please)

>I am using the OutputTo action in one of my macros. I have the Output File
> argument hard coded to a folder on my C drive. Is there a way to have that
[quoted text clipped - 5 lines]
>
> Frank
 
Sign In
Join
My Latest Posts
My Monitored Threads
My Blog
My Photo Gallery
My Profile
My Homepage

Start New Thread
Enable EMail Alerts
Rate this Thread



©2008 Advenet LLC   Privacy Policy - Terms of Use
This website includes both content owned or controlled by Advenet as well as content owned or controlled by third parties.