Examples: AddSetupChecklistItem()


The following example uses the AddSetupChecklistItem() function to add a new category as a first-level node in the Setup Checklist tree. The new category is defined by the CL_IG_Sample_Setup command list. The constant value SETUPCHECKLIST_TOPLEVEL indicates the category is being added to the top-level node in the tree. Because it is a category, no window technical name is needed. The constant IG_CHM_NAME contains the name of the help file from which to display a topic. The topic named “SampleSetup.htm” will be displayed from this help file.

local integer status;
local integer seq = 0;

status = AddSetupChecklistItem(DYNAMICS,
	SETUPCHECKLIST_TOPLEVEL,
	SETUPCHECKLIST_TOPLEVEL,
	seq,
	IG_PROD_ID,
	resourceid(form Command_IG_Sample),
	resourceid(command CL_IG_Sample_Setup of form Command_IG_Sample),
	"",
	false,
	"IG_CHM_NAME",
	"SampleSetup.htm") of form sySetupChecklistObj;

The following example uses the AddSetupChecklistItem() function to add a Setup Checklist item to the end of the Sales category already defined in the Setup Checklist. The new item is defined by the command IG_Contact_History_Setup. The technicalname() function is used to retrieve the technical name for the setup window being opened. The setup item will be displayed as required. The constant IG_CHM_NAME contains the name of the help file from which to display a topic. The topic named “ContactHistorySetup.htm” will be displayed from this help file.

local integer status;
local integer seq = 0;

status = AddSetupChecklistItem(DYNAMICS,
	resourceid(form Command_Sales),
	resourceid(command CL_Sales_Setup of form Command_Sales),
	seq,
	IG_PROD_ID,
	resourceid(form Command_IG_Sample),
	resourceid(command IG_Contact_History_Setup of form Command_IG_Sample),
	technicalname(window Contact_History_Setup of form IG_Contact_History_Setup),
	false,
	"IG_CHM_NAME",
	"ContactHistorySetup.htm") of form sySetupChecklistObj;

The following example uses the FindSetupChecklistItem() function to locate the Customer item in the Sales category of the Setup Checklist. The AddSetupChecklistItem() function is used to add a new category and item below the Customer node in the tree.

local integer status;
local integer seq;

{Find the Customers item}
seq = FindSetupChecklistItem(DYNAMICS,
	resourceid(form Command_Sales),
	resourceid(command CL_Sales_Setup of form Command_Sales),
	DYNAMICS,
	resourceid(form Command_Sales),
	resourceid(command RM_Customer_Maintenance of form Command_Sales)) of form sySetupChecklistObj;

{Add the new item after the Customers item}
seq = seq + 1;

status = AddSetupChecklistItem(DYNAMICS,
	resourceid(form Command_Sales),
	resourceid(command CL_Sales_Setup of form Command_Sales),
	seq,
	IG_PROD_ID,
	resourceid(form Command_IG_Sample),
	resourceid(command CL_IG_Sample_Setup of form Command_IG_Sample),
	"",
	false,
	"IG_CHM_NAME",
	"SampleSetup.htm") of form sySetupChecklistObj;

{Add an item to the new category}
seq = 0; {At the end}
status = AddSetupChecklistItem(IG_PROD_ID,
	resourceid(form Command_IG_Sample),
	resourceid(command CL_IG_Sample_Setup of form Command_IG_Sample),
	seq,
	IG_PROD_ID,
	resourceid(form Command_IG_Sample),
	resourceid(command IG_Contact_History_Setup of form Command_IG_Sample),
	technicalname(window Contact_History_Setup of form IG_Contact_History_Setup),
	false,
	"IG_CHM_NAME",
	"ContactHistorySetup.htm") of form sySetupChecklistObj;


Documentation Feedback