Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

How to find path to .cs file by its type in C#

Tags:

c#

How to find path to .cs file by its type?

Prototype of function:

string FindPath(Type);

Returns something like "C:\Projects\.....\MyClass.cs"

like image 306
satellite Avatar asked Jun 09 '12 10:06

satellite


1 Answers

That's not possible, there is no such relation. A class can be partial, so it can even come from several different source files.

like image 55
Guffa Avatar answered Sep 21 '22 20:09

Guffa