© 2026 Hedgehog Software, LLC

TwitterGitHubDiscord
More
CommunitiesDocsAboutTermsPrivacy
Search
Star
Setup for Free
C#C
C#•2y ago•
12 replies
Falcom

C# Environment variable

Hello,

I am a C# beginner and I want to modify the link of the dll to an env variable to work with several people on the project

I don't know if this is good practice but I put a variable like this in my csproj file

<Reference Include="TaleWorlds.MountAndBlade">
  <HintPath>$(MY_VARIABLE)\bin\myDll.dll</HintPath>
</Reference>
<Reference Include="TaleWorlds.MountAndBlade">
  <HintPath>$(MY_VARIABLE)\bin\myDll.dll</HintPath>
</Reference>


But I can't find how to add them then, I tried with the windows environment variables, I searched in Visual Studio 2022 but I couldn't find how to do it.

Thanks for your help
C# banner
C#Join
We are a programming server aimed at coders discussing everything related to C# (CSharp) and .NET.
61,871Members
Resources

Similar Threads

Was this page helpful?
Recent Announcements

Similar Threads

❔ C# double variable
C#CC# / help
3y ago
❔ c# access variable from other thread
C#CC# / help
3y ago
Get Environment Variables...
C#CC# / help
4y ago
Overriding appsettings.json section with environment variable
C#CC# / help
14mo ago