Example: Getting information about installed modules

You can use the ModuleCode variable that is provided in the HTML code on each Sage CRM screen to get information about the modules installed on the system. The ModuleCode variable is defined in the Eware.dll file.

To get information about the installed modules, locate the ModuleCode variable in the HTML code, and then get its value.

The ModuleCode variable can take one of the following integer values:

  • 1. Indicates that the Sales module is installed.
  • 2. Indicates that the Service module is installed.
  • 5. Indicates that the Sales and Marketing modules are installed.
  • 7. Indicates that the Sales, Marketing, and Service modules are installed.

Example

Copy
<script>

if(ModuleCode & 1) alert('Sales module is installed');
if(ModuleCode & 2) alert('Service module is installed');
if(ModuleCode & 5) alert('Sales and Marketing modules are installed');
if(ModuleCode & 7) alert('Sales, Marketing, and Service modules are installed');

</script>

Gets the value of the ModuleCode variable and displays information about installed modules on the screen.