0

Currently I have this in multiple projects:

<PropertyGroup>
    <InstallerMajorVersion>1</InstallerMajorVersion>
    <InstallerMinorVersion>09</InstallerMinorVersion>
    <InstallerBuildVersion>08</InstallerBuildVersion>
</PropertyGroup>
...
<PropertyGroup>
    <OutputName>Project-$(InstallerMajorVersion).$(InstallerMinorVersion).$(InstallerBuildVersion)</OutputName>
</PropertyGroup>

I'd like to have this information (the first PropertyGroup) in only one file, so I don't have to edit it in multiple places. However I need to import or somehow get to this information from every project file so I can set OutputName correctly.

How do you share properties/variables between multiple projects?

I didn't have much luck with my <Import /> approach: VS2010 - Using <Import /> to share properties between setup projects?

Community
  • 1
  • 1
  • You share properties between multiple projects using Import. If Import is not working for you then post more information about how you are using Import and what is wrong. – Brian Walker Sep 11 '12 at 15:33

2 Answers2

1

How about creating an altogether separate project just for loading this configuration stuff, and compiling it as a separate library / DLL? You could then use that DLL in each of the other projects where you need to import these settings.

Kjartan
  • 18,591
  • 15
  • 71
  • 96
0

It works using Import. I just had problems with VS2010 caching. See the linked issue for more details.