So I wrote something like this:API Docs wrote:Install (line 844)
Function that will get called as module is installed. This function should do any initialization functions including creating database tables. It should return a string message if there is a failure. Returning nothing (FALSE) will allow the install procedure to proceed.
void Install ()
Code: Select all
function Install() {
if (HaveAllRequirement() == true) {
... //proceed with install
} else {
return "This module cannot be installed because of X";
}
}