Solved

Using a variable to store files in the Application Directory?

Posted on 2014-10-15
2
96 Views
Last Modified: 2014-10-16
My application has functionality where it can store PDF files within a directory called "Certificates" somewhere inside the App directory structure. My question is, where would be the best place to store "Certificates" that will always be where it should be regardless of where on a drive the application is installed? Also, how do I access that directory within my VB.Net code. I've done this once before but it's been awhile and I don't remember what the object is to accomplish this.

Thanks!
0
Comment
Question by:BlakeMcKenna
2 Comments
 
LVL 29

Accepted Solution

by:
Paul Jackson earned 500 total points
ID: 40383330
You can use Application.StartupPath within your application to determine the path where your executable is on the drive, then your would append the string "\Certificates" to it to get your path for where to store your PDFs.
0
 

Author Closing Comment

by:BlakeMcKenna
ID: 40384117
Thanks Paul...that's what I was looking for.
0

Featured Post

Free Tool: Subnet Calculator

The subnet calculator helps you design networks by taking an IP address and network mask and returning information such as network, broadcast address, and host range.

One of a set of tools we're offering as a way of saying thank you for being a part of the community.

Question has a verified solution.

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

This tutorial demonstrates one way to create an application that runs without any Forms but still has a GUI presence via an Icon in the System Tray. The magic lies in Inheriting from the ApplicationContext Class and passing that to Application.Ru…
1.0 - Introduction Converting Visual Basic 6.0 (VB6) to Visual Basic 2008+ (VB.NET). If ever there was a subject full of murkiness and bad decisions, it is this one!   The first problem seems to be that people considering this task of converting…
Email security requires an ever evolving service that stays up to date with counter-evolving threats. The Email Laundry perform Research and Development to ensure their email security service evolves faster than cyber criminals. We apply our Threat…
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 …

829 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