0

I would like to place partial path to my references in my .target/.user file. For example MylibraryPath some thing similar to MSBuildToolsPath but my own custom path.

Later I would import my .target file into my .csproj and use MylibraryPath as $(MylibraryPath)\Reference\Win32\Release say.

How do I define MylibraryPath in my target fil. Can you please create a sample target file for me?

Thanks a lot!

Samsquanch
  • 8,866
  • 12
  • 50
  • 89
RadiumBall
  • 23
  • 6

1 Answers1

0

Read up on MsBuild properties

<PropertyGroup>
  <MyLibraryPath>C:\Program Files\Library\</MyLibraryPath>
</PropertyGroup>
Nicodemeus
  • 4,005
  • 20
  • 23
  • Incidentally I had created such a target file but visual studio editor gave me errors like "The element 'PropertyGroup' in namespace 'http://schemas.microsoft.com/developer/msbuild/2003' has an invalid child element 'MyLibraryPath'. But I guess trick is to simply ignore these errors... – RadiumBall Aug 28 '14 at 04:58
  • Yes, the automatic schema validation in VS should be ignored. – Nicodemeus Aug 28 '14 at 17:38