hey, here i have a question. i want to select a directory path alone... For example, by using "openfiledialog" control, we can select the file path (eg., d:\sample\dest.txt). But i want to select only the path (eg., d:\sample\).... can anyone help me ? thanks in advance...........
karan_21584
0
Light Poster
Recommended Answers
Jump to PostThis will return "d:\sample"
System.IO.Path.GetDirectoryName("d:\sample\dest.txt")
http://msdn2.microsoft.com/en-us/library/system.io.path.getdirectoryname.aspx
All 4 Replies
hollystyles
113
Veteran Poster
hollystyles
113
Veteran Poster
waynespangler
63
Posting Pro in Training
karan_21584
0
Light Poster
Be a part of the DaniWeb community
We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts meeting, networking, learning, and sharing knowledge.