A module is a Servoy solution that can be used as part of other solutions. It is commonly used to develop parts of a Servoy solution separately, to be combined later. Modules allow users to re-use graphical user interface objects and business logic in multiple solutions.
Creating a New Module
The process to create a module is similar to the one described in Working with Solutions.
- In Solution explorer, access the context menu on the currently active solution node and select Create New Solution.
- Specify the name of the module.
- Select Module as the solution type.
- Choose the resource project (usually the same resource project that the active solution is using).
- Click Finish.
- The new module will be added to the Modules node in the currently active solution, providing access to the module components.
- It will also be listed under the All Solutions node, from which the module can be activated and worked on as the currently active solution.
Adding an Existing Module to the Active Solution
There are two ways to add an existing module to the currently active solution.
To add a module via the Solution Explorer:
- Access the context menu on the desired solution/method listed in the All Solutions node.
- Select Add as Module.
- The solution will appear under the Modules node in the currently active solution.
To add multiple modules:
- Make sure the Properties view is active (usually on the right of the workbench). If not, open the view using the menu item Window>Show View>Properties.
- Double-click modulesNames under the Properties node. A select window will appear containing a list of all available solutions.
- Click the checkboxes for the solutions that you want to add as a module to the active solution.
Removing a Module from the Active Solution
To remove a module from the active solution, access the context menu (right-click) on the module and click Remove module. The removed module will remain in the All Solutions list for future use.