?
Solved

How to get Windows current directory character

Posted on 2014-09-19
3
Medium Priority
?
177 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
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
3 Comments
 
LVL 44

Accepted Solution

by:
AndyAinscow earned 1000 total points
ID: 40332248
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 1000 total points
ID: 40332255
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
ID: 40332264
Thank you
0

Featured Post

Technology Partners: 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

This document covers how to connect to SQL Server and browse its contents.  It is meant for those new to Visual Studio and/or working with Microsoft SQL Server.  It is not a guide to building SQL Server database connections in your code.  This is mo…
Performance in games development is paramount: every microsecond counts to be able to do everything in less than 33ms (aiming at 16ms). C# foreach statement is one of the worst performance killers, and here I explain why.
Do you want to know how to make a graph with Microsoft Access? First, create a query with the data for the chart. Then make a blank form and add a chart control. This video also shows how to change what data is displayed on the graph as well as form…
This tutorial will teach you the special effect of super speed similar to the fictional character Wally West aka "The Flash" After Shake : http://www.videocopilot.net/presets/after_shake/ All lightning effects with instructions : http://www.mediaf…
Suggested Courses

777 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