Go Premium for a chance to win a PS4. Enter to Win

x
?
Solved

Environmental Variable "tmp" Path / Access VBA

Posted on 2010-09-07
2
Medium Priority
?
619 Views
Last Modified: 2012-05-10
I have a piece of code that saves a file to the directory named in the environmetal variable path for tmp (i.e. in this case C:\...\...\...\My Documents).

As the exact string may change from user to user, i want to seach for the file based on the pathname stored in the environmental variable tmp and filename.

Is there a standard command to call this string value in access VB?

0
Comment
Question by:SweetingA
2 Comments
 
LVL 75
ID: 33619878
You mean

Environ("PATH")

?

mx
0
 
LVL 120

Accepted Solution

by:
Rey Obrero (Capricorn1) earned 2000 total points
ID: 33620142
use this

Environ("userprofile") & "\My Documents"

will give you

C:\Documents and Settings\<user Name>\My Documents
0

Featured Post

Industry Leaders: We Want Your Opinion!

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

You need to know the location of the Office templates folder, so that when you create new templates, they are saved to that location, and thus are available for selection when creating new documents.  The steps to find the Templates folder path are …
Access developers frequently have requirements to interact with Excel (import from or output to) in their applications.  You might be able to accomplish this with the TransferSpreadsheet and OutputTo methods, but in this series of articles I will di…
With Microsoft Access, learn how to specify relationships between tables and set various options on the relationship. Add the tables: Create the relationship: Decide if you’re going to set referential integrity: Decide if you want cascade upda…
With Secure Portal Encryption, the recipient is sent a link to their email address directing them to the email laundry delivery page. From there, the recipient will be required to enter a user name and password to enter the page. Once the recipient …
Suggested Courses

877 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question