I am trying to construct a file path in order to read an XSLT file, like so:
string path = \"../_xslt/example.xslt\";
StreamReader reader = new StreamReader(
string TestX()
{
string path = AppDomain.CurrentDomain.BaseDirectory; // You get main rott
string dirc = ""; // just var for use
string[] pathes = Directory.GetDirectories(path); // get collection
foreach (string str in pathes)
{
if (str.Contains("NameYRDirectory")) // paste yr directory
{
dirc = str;
}
}
return dirc; // after use Method and modify as you like
}