How to specify path in .config file relative to the file?
问题 An app I use interprets a .NET .config file. I added a line specifying the path to a certificate it needs <add key="Certificate" value="..\certificate.abc"/> However, I found the app only works when run from the exact folder its .exe and .config reside. If run from another folder, it fails, because it looks for the certificate at ../ expanded relative to the working directory . What should I write in the config file, to make sure the path is ..\certificate.abc expanded relative to the config