C
C#3y ago
İrşat

Environmental Variables in VS 2022 [Answered]

{
"profiles": {
"Library.Dependency": {
"commandName": "Project",
"environmentVariables": {
"MyLibs": "C:\\MyProject",
"Configuration": "Release"
}
}
}
}
{
"profiles": {
"Library.Dependency": {
"commandName": "Project",
"environmentVariables": {
"MyLibs": "C:\\MyProject",
"Configuration": "Release"
}
}
}
}
I am trying to get those environmental variables and write them here;
<PropertyGroup>
<OutputPath>$(MyLibs)\\$(Configuration)</OutputPath>
<Company>Software</Company>
<Authors>Software</Authors>
</PropertyGroup>
<PropertyGroup>
<OutputPath>$(MyLibs)\\$(Configuration)</OutputPath>
<Company>Software</Company>
<Authors>Software</Authors>
</PropertyGroup>
I realized that VS 2022 doesn't support this. So I experimented and used windows environmental variables instead. Mission accomplished unsuccessfully.
<OutputPath>%MyLibs%</OutputPath>
<OutputPath>%MyLibs%</OutputPath>
It finally shows something else than just C:\Debug. It doesn't work regardless. How do I do this normally? Oh and it would be nice if I could reach this damn thing from the entire project. There is one main project and some dependencies. All uses these.
1 Reply
Accord
Accord3y ago
✅ This post has been marked as answered!
Want results from more Discord servers?
Add your server