‎2012 Oct 09 2:47 PM
Hi,
I was debugging LIQS0F55 which contains a Function Module PM_NOTIFICATION_PRINT_CONTROL for print purpose.
while dubugging program doesn't enter this function module.
Since in both if and else condition the same FM is called so it must enter the FM anyway.
I think there is a field DEVICE in FM which should be added in the export parameters of FM in LIQS0F55.
IF T399J-DIALOG_PRT = SPACE. " Print in update task ???
CALL FUNCTION 'PM_NOTIFICATION_PRINT_CONTROL' IN UPDATE TASK
EXPORTING
IVIQMEL = VIQMEL
RIWO1 = RIWO1
QMNUM = VIQMEL-QMNUM
RIWO00 = RIWO00 "FOR STATUS INFO
PRINT_LANGUAGE = DEF_PRINT_LANGUAGE
RQM00 = RQM00
TABLES
IVIQMFE = IVIQMFE
IVIQMMA = IVIQMMA
IVIQMSM = IVIQMSM
IVIQMUR = IVIQMUR
IWORKPAPER = IWORKPAPER
IQKAT = IQKAT
IHPAD_TAB = IHPAD_TAB.
*... commit work will be issued in F00 later.
ELSE. " dialog print
CALL FUNCTION 'PM_NOTIFICATION_PRINT_CONTROL' "not in update task
EXPORTING
IVIQMEL = VIQMEL
RIWO1 = RIWO1 " texts workarea
QMNUM = VIQMEL-QMNUM
RIWO00 = RIWO00 "FOR STATUS INFO
PRINT_LANGUAGE = DEF_PRINT_LANGUAGE
RQM00 = RQM00
TABLES
IVIQMFE = IVIQMFE
IVIQMMA = IVIQMMA
IVIQMSM = IVIQMSM
IVIQMUR = IVIQMUR
IWORKPAPER = IWORKPAPER
IQKAT = IQKAT
IHPAD_TAB = IHPAD_TAB
EXCEPTIONS
NO_WORKPAPERS_PASSED = 01.
ENDIF.
This Device field in import parameters of FM.
DEVICE LIKE ITCPP-TDDEVICE 'PRINTER ' 'SCREEN' or 'PRINTER'
IVIQMEL LIKE VIQMEL SPACE QMEL field string (message)
PRINT_LANGUAGE LIKE T390_U-PRINT_LANG SYST-LANGU Ausgabesprachesvorlageswert
QMNUM LIKE IPRT_WA-QMNUM SPACE Message number
RIWO00 LIKE RIWO00 SPACE
RIWO1 LIKE RIWO1 SPACE
CAUFVD LIKE CAUFVD SPACE
ILOA LIKE ILOA SPACE
O_RIWO1 LIKE RIWO1 SPACE
RQM00 LIKE RQM00 SPACE spezielle E/A-Felder fuer Qualitätsmeldungen
Since this is the standard include program and FM i can't do R&D by adding or removing fields.
Can you suggest me that Am i thinking right?
If wrong what would be the correction.
‎2012 Oct 09 2:54 PM
The function module is called in update task( It is called after the commit)and thus it is not going inside with normal debugging. You have to do "Update debugging" by switching on Settings->Update debugging in the debugger and then it should enter inside the function module provided you put a break point.
‎2012 Oct 09 2:54 PM
The function module is called in update task( It is called after the commit)and thus it is not going inside with normal debugging. You have to do "Update debugging" by switching on Settings->Update debugging in the debugger and then it should enter inside the function module provided you put a break point.
‎2012 Oct 09 3:06 PM
Hi,
I did what you had suggested.
I placed a breakpoint at
IF T399J-DIALOG_PRT = SPACE. Switched on Update Debugging.
and I also placed a breakpoint in the source code of FM.
But still didn't enter in the FM.
Where else i should place a breakpoint?
‎2012 Oct 09 3:24 PM
After triggering the update debugging, press F8 and it should open a new window and then press F8 again to go to the FM. Make sure you re run the transaction after you have put the break point inside the source code of the FM
‎2012 Oct 10 8:20 AM
Thanx Rudra.
That was really helpfull.
I found the Message Id - S313(IM) in Include LIQS0F55 which is saying "The shop papers are printed when you exit the transaction".
But it is not happening when I am clicking on back button in transaction QM02 for Z3 type notifications.
The code regarding this must be somewhere near this message but i am unable to find it.
Can you help me on this??
‎2012 Oct 10 10:24 AM
Hi,
What I could make out here is :
Check the condition record for Z3 type notification. If it is not there the output will not be triggered. Also make sure when you press the back button, you are selecting "Yes" on the SAVE popup. Unless the transacton is saved successfully, your output will not be triggered.
Regards,
R