Answers for "c# relative file path in project example"

C#
0

c# relative path to project folder

string fileName = "ich_will.mp3";
string path = Path.Combine(Environment.CurrentDirectory, @"Data", fileName);
Posted by: Guest on September-03-2020
0

relative path c#

var outPutDirectory = Path.GetDirectoryName(Assembly.GetExecutingAssembly(). CodeBase);
var iconPath = Path.Combine(outPutDirectory, "Folder\Img.jpg");
string icon_path = new Uri(iconPath ).LocalPath;
Posted by: Guest on November-17-2021

C# Answers by Framework

Browse Popular Code Answers by Language