I currently have
<PropertyGroup>
<PostBuildEvent>copy "$(TargetPath)" "$(SolutionDir)Shared.Lib\$(TargetFileName)"</PostBuildEvent>
</PropertyGroup>
I want to do something like this, but one level above $(SolutionDir)
To switch this on in visual studio, go to Tools/Options then scroll down the tree view to the section called Projects and Solutions, expand that and click on Build and Run, at the right their is a drop down that specify the build output verbosity, setting that to diagnostic, will show you what other macro values you ...
Pre/Post build events are useful when we wish to perform some operations before/after a project is built. These operations are nothing but the Shell commands being used from the command line. Think of a scenario where we build our library project and its . dll is saved into the Project/bin/Release directory.
You can use ..\ to move up a directory.
<PropertyGroup>
<PostBuildEvent>copy "$(TargetPath)" "$(SolutionDir)..\Shared.Lib\$(TargetFileName)"</PostBuildEvent>
</PropertyGroup>
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With