I have several customers using the same application, but different customers have different needs. For example.
Default context menu
Customer 1 context menu
Customer 2 context menu
How can I create 1 project (with multiple 'Setups') that creates
Setup 1
Setup 2
Setup 3
Or is there another way to create different setups in visual studio for different customers without recompiling main application for each one.
One way would be using #if #endif
statements. You need to use #define
or put the symbol into the project (under Project Settings, Conditional compilation symbols). Only when a symbol is present at build time, this part of the code will be build. The other part is not accessible anymore. I think you can make a own solution configuration for each customer with own symbols. Building each configuration seperate, gives you a own dll for each customer.
How you deliver these dlls to your customers, is your problem. Own setups for each customer would be perfect but you can make your setup different, but i have no clue about complicated setups.
There is a way to set these symbols from the outside. Our company has a own application, that starts vs for us, with all configs we want. I only know that we put a variable into the cs projects and thats get filled beforehand.
The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.