0

I'm a self-taught scripter/programmer and I'm about to sell the first licenses of a product I've designed. The product will have different areas accessible/inaccessible based on the customer's original purchase and contract selected.

I can see the multiple versions of my project becoming unwieldy, especially when I find a problem/bug that needs an update across all versions regardless of what version the customer has purchased.

So, my question is whether, in Visual Studio, there is a way to have one project with multiple versions that can be deployed based on who (which customer or location) is installing it? I plan on using 'Click Once' deployment to distribute the software although I'm open to other methods of deployment if it will help me with this problem.

I looked for a while through the forums and couldn't find a question that related enough to my situation to implement, sorry if I overlooked something.

Any help is greatly appreciated. Thanks in advance!

Jon
  • 41
  • 5
  • There are a number of things one can do to provide different behaviors/versions of a program to users depending on some criteria. A comprehensive answer would be too lengthy and cover too much different ground to be suitable for Stack Overflow. That said, the simplest approach is conditional compilation, i.e. use `#if` compiler directive. Setting an appropriate defined name for compilation is the first step, and this can be done in a variety of ways. See duplicate. – Peter Duniho Apr 14 '21 at 03:32
  • It also depends on how much you trust your users. You could include all features in your app, but have configuration that turns features on and off. The trick is having deployable configuration that isn't easily discoverable by your users (discoverable enough to cheat). Assuming your app is installable by users, it's a bit easier to do this if the app has access to the internet (you could do a "enter the program key" feature on first run, and have it communicate to a server to get the appropriate configuration flags (that you cache in a reasonably hidden place on the client – Flydog57 Apr 14 '21 at 03:58
  • I would recommend two (or more) projects. Your paid version can depend on your free version, or you could `Link` the same source files into both projects. – Jeremy Lakeman Apr 14 '21 at 04:58
  • Describe more the number of variations you plan on deploying. Personally I'd look at creating vital parts of the system as a web app so you remain in control of the code. End of the day, .net apps are easy to hack but for any language, if you give your app to a customer you lose control of it – Caius Jard Apr 14 '21 at 05:35

0 Answers0