Please help me to understand how to find/capture the correct Function Name to register a script against.
I am trying to register a script based on a function that is running from the form RM Transaction Edit. I have read the IG guide and other PROG 1&II dexterity documentation.
I understand the syntax
Trigger_RegisterFunction(function function_name {of form form_name}, attach_type, [function processing_function | script processing_procedure] {, tag})
The problem I encounter is how to correctly determine the function name (and correct syntax) to register in the Startup script.
First I create a script log and identify the function that I want to trigger. I am pasting part of the script from the Receivables Transaction Edit screen.
'RM_Edit_Transaction Next Button - Window Area CHG on form RM_Edit_Transaction'
'RM_Edit_Transaction Browse Buttons CHG on form RM_Edit_Transaction'
'RM_PostedDocExistsInWork()', 0, "CREDT000000000001", 7, "XRM_Sales", "sa", 0
'IsRMCashReceipt()', 0, 7
'RM_Edit_Transaction RM Document Type-All CHG on form RM_Edit_Transaction'
'RM_Edit_Transaction Temp Control Number CHG on form RM_Edit_Transaction'
'ClearDocument of form RM_Edit_Transaction'
'RM_PostedDocExistsInWork()', 0, "CREDT000000000001", 7, "XRM_Sales", "sa", 0
'IsRMCashReceipt()', 0, 7
'MC_Is_MC_Transaction', "Z-US$", 0
'RM_Edit_Transaction RM Document Type-All CHG on form RM_Edit_Transaction'
I have also created a Profile script and can see which lines are P and which are F (Procedures and Functions)
'RM_Edit_Transaction RM Document Type-All CHG on form RM_Edit_Transaction' is a Function
But no matter how I register it in Dexterity Startup, I am getting a syntax error.
The following is how I registered in Dexterity Startup
local integer l_result;
l_result = Trigger_RegisterFunction(function 'Document Type-All CHG' of form RM_Edit_Transaction, TRIGGER_AFTER_ORIGINAL, script Zint_RM_Edit_CMNo_FieldFocusTrigger);
if l_result <> SY_NOERR then
warning "The Zint_RM_Edit_CMNo_FieldFocusTrigger trigger is not registered.";
end if;
error message
Unknown Identifer ''RM Document Type-All CHG'. (Line 42)
Type incompatibility 'Script Function Trigger_RegisterFunction, Parameter#1'. (line 42)
I have tried substituting RM_Edit_Transaction RM Document Type-All CHG for the fucntion name...) similar error.
local integer l_result;
l_result = Trigger_RegisterFunction(function 'RM Document Type-All CHG' of form RM_Edit_Transaction, TRIGGER_AFTER_ORIGINAL, script Zint_RM_Edit_CMNo_FieldFocusTrigger);
if l_result <> SY_NOERR then
warning "The Zint_RM_Edit_CMNo_FieldFocusTrigger trigger is not registered.";
end if;
Please advise