Solved

How to get Windows current directory character

Posted on 2014-09-19
3
162 Views
Last Modified: 2014-09-19
Hi, in .Net '\' is returned by
System.IO.Path.DirectorySeparatorChar

Open in new window

Is there a similar constant for '.', the current directory?
The only details I can find are here: http://msdn.microsoft.com/en-us/library/system.io.path.pathseparator(v=vs.110).aspx
Thank you
John
0
Comment
Question by:John Bolter
3 Comments
 
LVL 44

Accepted Solution

by:
AndyAinscow earned 250 total points
Comment Utility
I thought the 'dot' was a standard character for that.

Anyway you could laways specifically get the current directory to be certain:
http://msdn.microsoft.com/en-us/library/system.io.directory.getcurrentdirectory%28v=vs.110%29.aspx

// Get the current directory.
            string path = Directory.GetCurrentDirectory();
0
 
LVL 15

Assisted Solution

by:Haris Djulic
Haris Djulic earned 250 total points
Comment Utility
Dot is not reserved character so there is no special constant created for it ..

More details can be found here :

http://msdn.microsoft.com/en-us/library/aa365247%28v=vs.85%29.aspx#naming_conventions
0
 

Author Closing Comment

by:John Bolter
Comment Utility
Thank you
0

Featured Post

Better Security Awareness With Threat Intelligence

See how one of the leading financial services organizations uses Recorded Future as part of a holistic threat intelligence program to promote security awareness and proactively and efficiently identify threats.

Join & Write a Comment

Introduction Hi all and welcome to my first article on Experts Exchange. A while ago, someone asked me if i could do some tutorials on object oriented programming. I decided to do them on C#. Now you may ask me, why's that? Well, one of the re…
Calculating holidays and working days is a function that is often needed yet it is not one found within the Framework. This article presents one approach to building a working-day calculator for use in .NET.
Illustrator's Shape Builder tool will let you combine shapes visually and interactively. This video shows the Mac version, but the tool works the same way in Windows. To follow along with this video, you can draw your own shapes or download the file…
Polish reports in Access so they look terrific. Take yourself to another level. Equations, Back Color, Alternate Back Color. Write easy VBA Code. Tighten space to use less pages. Launch report from a menu, considering criteria only when it is filled…

771 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

Need Help in Real-Time?

Connect with top rated Experts

11 Experts available now in Live!

Get 1:1 Help Now