C# – Compact Framework Current Folder

ccompact-frameworkvb.netwindows-mobile

How do I know which is the current folder of an App?

I mean… Is there a way to know where is the exe located from the running code?

Best Answer

Windows Mobile doesn't have the concept of a current folder. The "current folder" is basically always set to be the root of the filesystem, no matter where your application is located.

To get the path your application is located, you can use Assembly.GetExecutingAssembly(), and the CodeBase property or GetName() method