473,387 Members | 1,553 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,387 software developers and data experts.

USER HOME DIRECTORY

Hi all,

I am writing a desktop application. Now, I am having
problem figuring out the <Home Dir> path of a user.

I want to store user-specific data and I heard that
there's an easy way in .net to get the <Home Dir>.

Any help/suggestion would be greatly appreciated.
Thank you very much in advance.
regards,
Sean
Nov 16 '05 #1
2 15795
Hi Sean,

string userHomePath =
Path.Combine(Environment.GetFolderPath(Environment .SpecialFolder.ApplicationData)
, "..");

But i can recommand to use path:

string yourAppPath =
Path.Combine(Environment.GetFolderPath(Environment .SpecialFolder.ApplicationData)
, "YourApp");

Cheers!

Marcin
Hi all,

I am writing a desktop application. Now, I am having
problem figuring out the <Home Dir> path of a user.

I want to store user-specific data and I heard that
there's an easy way in .net to get the <Home Dir>.

Any help/suggestion would be greatly appreciated.
Thank you very much in advance.
regards,
Sean

Nov 16 '05 #2
Hi Marcin,

Thank you very much for your reply. :)
regards,
Sean
-----Original Message-----
Hi Sean,

string userHomePath =
Path.Combine(Environment.GetFolderPath (Environment.SpecialFolder.ApplicationData) , "..");

But i can recommand to use path:

string yourAppPath =
Path.Combine(Environment.GetFolderPath (Environment.SpecialFolder.ApplicationData) , "YourApp");

Cheers!

Marcin
Hi all,

I am writing a desktop application. Now, I am having
problem figuring out the <Home Dir> path of a user.

I want to store user-specific data and I heard that
there's an easy way in .net to get the <Home Dir>.

Any help/suggestion would be greatly appreciated.
Thank you very much in advance.
regards,
Sean

.

Nov 16 '05 #3

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

1
by: Alex Leduc | last post by:
Is there an API function to get the user's home directory path in Java? I'd like to save a configuration file in it. For a user named "myUser", I would get /home/myUser on Linux ...
0
by: Gabriel Cooper | last post by:
In one of my python programs has a data file I need to load. My solution was to say: if os.path.exists(os.path.join(os.getcwd(), "config.xml")): self.cfgfile = os.path.join(os.getcwd(),...
15
by: scmiles | last post by:
I am trying to write an asp or aspx page that will create a virtual ftp directory to the users Active Directory home directory. That way a user can interact (drag/drop, copy/paste) via IE with...
4
by: Ed | last post by:
Hello All, I posted earlier about a problem I was having with editing or pasting/deleting files in the "Home Directory" of my web server. I just noticed that the "Home Directory" option in the...
0
by: Don Rozenberg | last post by:
Hello, I'm successfully running MySql under Debian with the data files in /var/lib/mysql. I would like to move the data base files to my home directory and have mysql use them from there. How...
4
by: Krunom Ancini | last post by:
Hi, all stuff works fine if i define absolute paths but with relative i have some problems: i defined my at Internet Information Services (IIS) home directory of my "default web site" and I...
6
by: Hemant Shah | last post by:
Folks, I need to move HOME directory of an instance to another directory. What is the best way of doing it? Is changing password file enough? or dies DB2 store this info in it's own config? ...
6
by: lawpoop | last post by:
I'm working on a PHP site and I have my database password file behind the server root directory. I can reference the password file by include("../ database_password.inc.php"), but I would like...
0
by: taylorcarr | last post by:
A Canon printer is a smart device known for being advanced, efficient, and reliable. It is designed for home, office, and hybrid workspace use and can also be used for a variety of purposes. However,...
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
0
by: ryjfgjl | last post by:
If we have dozens or hundreds of excel to import into the database, if we use the excel import function provided by database editors such as navicat, it will be extremely tedious and time-consuming...
0
by: ryjfgjl | last post by:
In our work, we often receive Excel tables with data in the same format. If we want to analyze these data, it can be difficult to analyze them because the data is spread across multiple Excel files...
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
0
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...
0
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.