Daqmx "Done" event not triggering event structure
I would like the user to be able to abort my daqmx task by pressing a button.
I am attempting to use the method in this VI:
https://decibel.ni.com/content/docs/DOC-15815
It utilizes an event structure with the daqmx Control Task VI to abort.
The example VI above works for me, on my system with my USB-6356 device, as expected.
When I attempt to incorporate the same method into my VI it does not--despite having an identical arrangement, so far as I can tell.
I believe that my problem lies with the event structure, and the dynamic registration. I am unfamiliar with this and must be using it incorrectly.
I have attached my VI, though it is cumbersome. The code which I am struggling with is in the "Acquire" case. As far as I can tell, I am doing exactly the same this in this particular case as in the example mentioned. Yet in the example, the event structure completes, or aborts, whatever you want to call it, right after the "Wait Until Done" VI executes. In my own VI, the "Wait Until Done" and "Clear Task" VIs execute, but the event structure does not register it.
Here are my specific questions: is there anything extra or special that one must do in order for the Task to properly trigger a "Done" event and pass through the event structure? At what point is the daqmx task "Done"?
thanks,
Matt
Attachments:
BoomTubeMain.vi 175 KB
natasftw,
My event structure is identical to theirs; what you are seeing are the two different cases that exist in the event structure. In both the example and the VI, there is a <task out>: Done and a "Dynamic Event": Value Change. In the dynamic event case, I have my abort button and relevant code--this I believe is the code you were referring to, which you thought I was missing... Regarding my multiple event structures, they should operate completely independently as they respond to different events.
Similar Messages
-
BUS2032 - ALECHANGED event not triggering
Hi Gurus,
I have a issue in our dev system. In our system automatic PO creation is configured through Sales order.
This is working fine in Regression and production systems, but not working in Dev system.
I have compared the Regression and Dev system and I found that the ALECHANGED event is not triggering in our Dev system.
I have checked the Item Category of the Sales Order and it is same in both the systems.
And also I have checked all possible Workflow transaction(SWUE, SWEL, SWU3, SWU0, SWETYPV), everything looks same in both the systems.
Now I am not sure what to check and where to check.
Please let me whereelse/whatelse I have to check. Is there any ALE configuration to be checked.
Thanks for your help in advance.
Thanks,
Murali.Hi Susan,
Thanks for the reply.
I know there could be some config missing but don't know what config it is.
There are more than 100 users in our Dev Systems, so I can't check the transports. It would be helpful for me if I get specific TCodes or areas so that I can compare my dev system with other systems where it is working fine.
Thanks,
Murali. -
Subtype event not triggering and supertype event triggers twice!!!!!!
Hi,
We have created a subtype for object bus2030 and also an event created for that. My workflow should trigger whenever an inquiry is created.
I've maintained this as triggering event in SWDD and done type linkage is SWE2 and everything looks fine.
When i simulate or create event the WF is triggered but when create inquiry in VA11 WF does not triggers.
I've checked SWEL for event trace but no event is triggered at all... Am i missing something... I've done almost everything that i used to do...
Even synchronized buffer!!! nothing paid me a solution...
Infact the same was working with 3.1i system but after migration to ECC6 we had to create new WF template for the same Process.
Now I also see that the supertype bus2030-created event is triggered twice but, obviously no receiver type exists. But the zbus2030 event is not being triggered at all!!!!
Kindly help me understanding my mistake...
Regards,
PBHope you have already set the deletegation in SWO6.
Now, event dont get triggered automatically, jus because they are defined in object. They have to be explicitly published in thesystem.
Check for a suitable user exit in your transaction, which makes use of function module to create the event, from that you know how to proceed.
If you dont find user exit, try other triggering techniques such as change documents, logistics, BTEs... etc.
regards,
Sandeep Josyula -
Hi,
We have created a custom workflow for notifcation purpose when shopping cart is fully approved. We are working on SRM 5.0 and classic scenario is implemented.
To start this workflow we used event "FinishedApproval" of BO BUS2121. But this event is not triggered in system when shopping cart is fully approved.
No events are registered in event trace too.
when event is triggered using SWUE, workflow is started as desired.
We are using N-step SC approval workflow and it is working perfectly fine. Notification workflow is desired to start after completion of approval workflow.
Kindly provide some solution for this issue.
Regards,
BrajvirHi Maksim,
I meant none of the click events in the DOM are triggered while loading sap.m library as dependency via Component.js but works fine while the sap.m library is loaded via bootstrap.
I supposedly think the events are bounded before the DOM is loaded but I m bit surprised with the behavior since there nothing changed in the structure apart from sap.m library loading from different location.
Thanks,
Ajain -
BSP Terminating event not triggering
Hello Friends,
We have a scenario, where a BSP application is triggered from a Workflow, for a certain approval, and after the user clicks on Approve button on the BSP Page, the BSP would write to the workflow container using SAP_WAPI_WRITE_CONTAINER and then we call SWF_WSC_CALLBACK_LAUNCH.
This used to work, but after an almost Fatal incident with our system, we are not able to get this to work.
We can see in the workflow log that the container is written, but the terminating event is not triggered, and the workflow doesn't move forward
Is there a setting that we're missing..??
Thanks,
Tat.Have you tried:
call function 'SAP_WAPI_DECISION_COMPLETE' -
URGENT:PR event not triggering
Hi Experts,
I am creating a PR through me51n.It should create an event of BUS2009(Releasestepcreated).But not event is triggering.Is it related to some setting in SPRO.Please help meHi Vivek,
Hope you have gone thru' SAP help for the customizing requiredfor this scenaro.
Pls re-check all your customizing steps from MM side and also if you have mentioned the workflow indicators in the MM config, which indicate that workflow has to be used for release starategy.
Regds,
Akshay -
Business Event not triggering the PLSQL procedure.. What to do?
We need to call a plsql procedure when the GL Approval workflow has ended with approval. I thought i could do this by customizing the relevant business event.
We are on EBS 12.1.3 with RDBMS : 11.2.0.3.0.
I saw that the business event oracle.apps.gl.Journals.journal.approve was disabled currently. I enabled it and created a subscription for it. Subscription was a PLSQL procedure. Currently, for test purpose only thing it is doing is to insert a row into a table.
Business Event Subscription settings:
System: ORDEBS.SYSTEM.COM
Triggering Event
Source Type:Local
Event Filter: oracle.apps.gl.Journals.journal.approve
Execution Condition
Phase: 100
Status: Enabled
Rule Data: Message
Action Type:Custom
On Error: Stop and Rollback
Action
PL/SQL Rule Function: XX_GL_APPROVE_BE_PKG.Get_Attributes
Priority: Normal
Documentation (Not sure what value to be given for these. I went with the below values.)
Owner: Company Name
Owner Tag: Custom Schema
Using the below query i can see that the business event is getting called when the approval happens (One row added each time approval happened). But I cant see any rows in the table where it should insert a row. What could be going wrong? How can i verify that the procedure has been called?
select * from WF_DEFERRED where corrid ='APPS:oracle.apps.gl.Journals.journal.approve'
Procedure:
CREATE OR REPLACE PACKAGE BODY APPS.XX_GL_APPROVE_BE_PKG
AS
PROCEDURE Get_Attributes
IS
BEGIN
INSERT INTO xx.xx_test_table VALUES ('From BE');
COMMIT;
END Get_Attributes;
END XX_GL_APPROVE_BE_PKG;Thanks Alejandro. Now this is working.
Changes i made:
1. Added the WFERROR workflow as a subscription to this event. So i could see that the function i am calling from the event did not have proper signature.
2. Changed the function signature to have standard parameters like:
CREATE OR REPLACE PACKAGE BODY XX_GL_APPROVE_BE_PKG
AS
function subscription(p_subscription_guid in raw,
p_event in out nocopy wf_event_t) return varchar2 is
l_result varchar2(20);
begin
insert into xxvtv.xxvtv_test_table values ('From BE');
commit;
exception
when others then
wf_core.context('XX_GL_APPROVE_BE_PKG','function subscription', p_event.getEventName(), p_event.getEventKey());
wf_event.setErrorInfo(p_event, 'ERROR');
return 'ERROR';
end subscription;
END XX_GL_APPROVE_BE_PKG;
3. Changed the owner name and owner tag both to the custom schema name (XX) -
Subsequent event not triggering​?
i have a MAIN VI and a SUB VI which communicate events through control refnum. flow of events is as follows.
1) sub vi changes a value of its control and this event is handled in the main vi(this works)
2)main vi in response to the event changes one of its control and triggers an event from the event handler itself which is handled in the subvi event handler.
the first phase is over. now the main vi is running a while loop and the sub vi is running a while loop and main vi triggeres an event every ~150ms. which is to be handled in the subvi. this is the part which is not happening. i can see the main vi's control getting updated but the event(if generated) is not handled by the subvi. i'm using control's property node->Value(signalling) to change the value as well as trigger the event. what can be the possible cause?
hope my question is clear.
Solved!
Go to Solution.i found the problem .
the subsequent events were not being handled because the loop in which the event handler ran looped **once**
i.e the initial condition was itself false so the loop only ran once.
this loop was controlled by `stop if true`. it had to be `continue if true`.
the boolean variable that controlled this loop was true. this should have been my first clue.
sorry for the trouble -
MouseListener event not triggering sometimes
lineTable = atmBean1.getReturnTable();
//remove the other columns
lineTable.removeColumn(lineTable.getColumnModel().getColumn(21));
lineTable.removeColumn(lineTable.getColumnModel().getColumn(20));
lineTable.addMouseListener(new MouseAdapter() {
public void mouseClicked(MouseEvent e) {
setChargesPanel();
public void setChargesPanel()
lblConsdData.setText(mainPanel.formatDollar(Double.parseDouble(String.valueOf(atmBean1.tm.getValueAt(lineTable.getSelectedRow(),11)))));
lblAllowedData.setText(mainPanel.formatDollar(Double.parseDouble(String.valueOf(atmBean1.tm.getValueAt(lineTable.getSelectedRow(),13)))));
lineChargesPanel.validate();
lineChargesPanel.repaint();
}when the JTable is set with some data, i have another GUI which has some labels , when the row is selected the corresponding values are taken from the original table model and is displayes in the JLabels.
Sometimes, when the mouse is clicked it is not triggering thisis it just because its Swing GUI.. the JTable rows sometimes get selected but the event is not triggered when the mouse is clicked, maybe the API is not good ???????.
-
Events not triggering in alv list, point will be given
Hi friends,
I am using reuse_alv_list_display fm to display data.
and i am using reuse_alv_events_get fm to trigger events.
but, top_of_page, event is not triggering,
more precisely , the subroutine is not getting recognized by system. how to rectify this.
Check my code.
*& Report ZSEN_SERVICETAX_GTA
REPORT zsen_servicetax_gta NO STANDARD PAGE HEADING LINE-COUNT 100.
*****************************************TABLES USED**********************************************************************
*TABLES: BSIS, "Accounting: Secondary Index for G/L Accounts
BSAS, "Accounting: Secondary Index for G/L Accounts (Cleared Items)
LFA1. "Vendor Master (General Section).
*****************************************WORK AREA / INTERNAL TABLE DECLARATION******************************************
TYPE-POOLS: slis.
TYPES: BEGIN OF ty_main,
hkont TYPE bsis-hkont,
belnr TYPE bsis-belnr,
budat TYPE bsis-budat,
blart TYPE bsis-blart,
dmbtr TYPE bsis-dmbtr,
xblnr TYPE bsis-xblnr,
shkzg TYPE bsis-shkzg,
augbl TYPE bsis-augbl,
kz_dmbtr TYPE bsis-dmbtr,
kz_xblnr TYPE bsis-xblnr,
kz_blart TYPE bsis-blart,
kz_belnr TYPE bsis-belnr,
kz_budat TYPE bsis-budat,
kz_zuonr TYPE bsis-zuonr,
name1 TYPE lfa1-name1,
slno TYPE i,
END OF ty_main,
BEGIN OF ty_bsas,
belnr TYPE bsas-hkont,
budat TYPE bsas-budat,
xblnr TYPE bsas-xblnr,
augbl TYPE bsas-augbl,
dmbtr TYPE bsas-dmbtr,
blart TYPE bsas-blart,
zuonr TYPE bsas-zuonr,
END OF ty_bsas.
DATA: it_main TYPE TABLE OF ty_main,
wa_main LIKE LINE OF it_main,
it_bsas TYPE TABLE OF ty_bsas,
wa_bsas LIKE LINE OF it_bsas.
DATA: it_sort TYPE slis_t_sortinfo_alv,
fieldcatalog TYPE slis_t_fieldcat_alv WITH HEADER LINE,
gd_layout TYPE slis_layout_alv,
gt_events TYPE slis_t_event,
int_fcat TYPE slis_fieldcat_alv,
it_header TYPE slis_t_listheader,
wa_header TYPE slis_listheader.
************************************************work variables***********************************************************************
DATA: ven_name TYPE lfa1-name1,
post_date TYPE bsis-budat,
t_tabix TYPE sy-tabix,
i_prg LIKE sy-repid.
***********************************************selection screen***********************************************************************
SELECTION-SCREEN: BEGIN OF BLOCK gtn WITH FRAME TITLE text-001 .
SELECT-OPTIONS: date FOR post_date OBLIGATORY.
SELECTION-SCREEN: END OF BLOCK gtn.
************************************************data selection**************************************************************************
START-OF-SELECTION.
PERFORM data_retreval.
PERFORM build_catalog.
PERFORM layout.
PERFORM build_events.
PERFORM sortinfo.
IF it_main[] IS NOT INITIAL.
PERFORM display_alv.
ELSE.
MESSAGE 'No Records Matching For This Selection' TYPE 'E'.
ENDIF.
******************************data display*********************************************************************************************
*& Form data_retreval
text
--> p1 text
<-- p2 text
FORM data_retreval .
CLEAR:it_main[], wa_main, fieldcatalog[].
***********************************************selecting data from bsis table for the given date range**********************************
SELECT ahkont abelnr abudat ablart admbtr axblnr a~shkzg
b~augbl
INTO CORRESPONDING FIELDS OF TABLE it_main
FROM bsis AS a LEFT OUTER JOIN bsas AS b
ON abelnr = bbelnr
WHERE a~budat IN date
AND a~blart = 'KR'
AND a~shkzg = 'S'
AND a~hkont = '0002200530'.
***********************************************selecting data from bsas table using bsis-belnr*******************************************
LOOP AT it_main INTO wa_main.
SELECT belnr budat dmbtr xblnr zuonr augbl blart
INTO CORRESPONDING FIELDS OF wa_bsas
FROM bsas
WHERE belnr = wa_main-augbl
AND blart = 'KZ'.
ENDSELECT.
APPEND wa_bsas TO it_bsas.
ENDLOOP.
********************************************combining two tables data******************************************************************
LOOP AT it_main INTO wa_main.
t_tabix = sy-tabix.
wa_main-slno = t_tabix.
READ TABLE it_bsas INTO wa_bsas WITH KEY augbl = wa_main-augbl.
IF sy-subrc = 0.
SELECT SINGLE name1
FROM lfa1
INTO ven_name
WHERE lifnr = wa_bsas-zuonr.
wa_main-kz_dmbtr = wa_bsas-dmbtr.
wa_main-kz_belnr = wa_bsas-belnr.
wa_main-kz_blart = wa_bsas-blart.
wa_main-kz_budat = wa_bsas-budat.
wa_main-kz_xblnr = wa_bsas-xblnr.
wa_main-kz_zuonr = wa_bsas-zuonr.
wa_main-name1 = ven_name.
ENDIF.
MODIFY it_main FROM wa_main INDEX t_tabix TRANSPORTING kz_dmbtr kz_belnr kz_budat kz_blart kz_xblnr kz_zuonr name1 .
ENDLOOP.
SORT it_main BY kz_blart kz_zuonr.
LOOP AT it_main INTO wa_main.
wa_main-slno = sy-tabix.
MODIFY it_main FROM wa_main INDEX sy-tabix TRANSPORTING slno.
ENDLOOP.
ENDFORM. " data_retreval
*& Form build_catalog
text
--> p1 text
<-- p2 text
FORM build_catalog .
DATA: col_pos TYPE i.
col_pos = col_pos + 1.
fieldcatalog-fieldname = 'SLNO'.
fieldcatalog-seltext_m = 'Serial No'.
fieldcatalog-col_pos = col_pos.
APPEND fieldcatalog TO fieldcatalog.
CLEAR: fieldcatalog.
col_pos = col_pos + 1.
fieldcatalog-fieldname = 'KZ_ZUONR'.
fieldcatalog-seltext_m = 'Vendor Num'.
fieldcatalog-col_pos = col_pos.
APPEND fieldcatalog TO fieldcatalog.
CLEAR: fieldcatalog.
col_pos = col_pos + 1.
fieldcatalog-fieldname = 'NAME1'.
fieldcatalog-seltext_m = 'Vendor Name'.
fieldcatalog-col_pos = col_pos.
APPEND fieldcatalog TO fieldcatalog.
CLEAR: fieldcatalog.
col_pos = col_pos + 1.
fieldcatalog-fieldname = 'BLART'.
fieldcatalog-seltext_m = 'BillDoc.Type'.
fieldcatalog-col_pos = col_pos.
APPEND fieldcatalog TO fieldcatalog.
CLEAR: fieldcatalog.
col_pos = col_pos + 1.
fieldcatalog-fieldname = 'BELNR'.
fieldcatalog-seltext_m = 'BillDoc.Num.'.
fieldcatalog-col_pos = col_pos.
APPEND fieldcatalog TO fieldcatalog.
CLEAR: fieldcatalog.
col_pos = col_pos + 1.
fieldcatalog-fieldname = 'BUDAT'.
fieldcatalog-seltext_m = 'BillPosting Date'.
fieldcatalog-col_pos = col_pos.
APPEND fieldcatalog TO fieldcatalog.
CLEAR: fieldcatalog.
col_pos = col_pos + 1.
fieldcatalog-fieldname = 'XBLNR'.
fieldcatalog-seltext_m = 'BillReference Num'.
fieldcatalog-col_pos = col_pos.
APPEND fieldcatalog TO fieldcatalog.
CLEAR: fieldcatalog.
col_pos = col_pos + 1.
fieldcatalog-fieldname = 'DMBTR'.
fieldcatalog-seltext_m = 'Bill Amount'.
fieldcatalog-col_pos = col_pos.
fieldcatalog-do_sum = 'X'.
APPEND fieldcatalog TO fieldcatalog.
CLEAR: fieldcatalog.
col_pos = col_pos + 1.
fieldcatalog-fieldname = 'KZ_BLART'.
fieldcatalog-seltext_m = 'Pay_Doc.type'.
fieldcatalog-col_pos = col_pos.
fieldcatalog-do_sum = 'X'.
APPEND fieldcatalog TO fieldcatalog.
CLEAR: fieldcatalog.
col_pos = col_pos + 1.
fieldcatalog-fieldname = 'KZ_BELNR'.
fieldcatalog-seltext_m = 'Pay_Document No'.
fieldcatalog-col_pos = col_pos.
APPEND fieldcatalog TO fieldcatalog.
CLEAR: fieldcatalog.
col_pos = col_pos + 1.
fieldcatalog-fieldname = 'KZ_DMBTR'.
fieldcatalog-seltext_m = 'Payment Amount'.
fieldcatalog-col_pos = col_pos.
fieldcatalog-do_sum = 'X'.
APPEND fieldcatalog TO fieldcatalog.
CLEAR: fieldcatalog.
col_pos = col_pos + 1.
fieldcatalog-fieldname = 'KZ_XBLNR'.
fieldcatalog-seltext_m = 'Pay_Reference Num'.
fieldcatalog-col_pos = col_pos.
APPEND fieldcatalog TO fieldcatalog.
CLEAR: fieldcatalog.
col_pos = col_pos + 1.
fieldcatalog-fieldname = 'KZ_BUDAT'.
fieldcatalog-seltext_m = 'Pay_Posting Date'.
fieldcatalog-col_pos = col_pos.
APPEND fieldcatalog TO fieldcatalog.
CLEAR: fieldcatalog.
col_pos = col_pos + 1.
fieldcatalog-fieldname = 'AUGBL'.
fieldcatalog-seltext_m = 'Clr.Doc.Num'.
fieldcatalog-col_pos = col_pos.
fieldcatalog-row_pos = 2.
APPEND fieldcatalog TO fieldcatalog.
CLEAR: fieldcatalog.
ENDFORM. " build_catalog
*& Form sortinfo
text
--> p1 text
<-- p2 text
FORM sortinfo .
DATA: is_sort TYPE slis_sortinfo_alv.
CLEAR:is_sort.
is_sort-spos = 2.
is_sort-fieldname = 'KZ_ZUONR'.
is_sort-up = 'X'.
APPEND is_sort TO it_sort.
CLEAR: is_sort.
is_sort-spos = 1.
is_sort-fieldname = 'KZ_BLART'.
is_sort-up = 'X'.
is_sort-subtot = 'X'.
APPEND is_sort TO it_sort.
ENDFORM. " sortinfo
*& Form layout
text
--> p1 text
<-- p2 text
FORM layout .
gd_layout-no_input = 'X'.
gd_layout-colwidth_optimize = 'X'.
gd_layout-zebra = 'X'.
*gd_layout-totals_text = 'Grand Total'.
*gd_layout-subtotals_text = 'BillBooked Not Paid'.
ENDFORM. " layout
*& Form display_alv
text
--> p1 text
<-- p2 text
FORM display_alv .
i_prg = sy-repid.
CALL FUNCTION 'REUSE_ALV_LIST_DISPLAY'
EXPORTING
I_INTERFACE_CHECK = ' '
I_BYPASSING_BUFFER = ' '
I_BUFFER_ACTIVE = ' '
i_callback_program = 'I_PRG'
I_CALLBACK_PF_STATUS_SET = ' '
I_CALLBACK_USER_COMMAND = ' '
I_CALLBACK_TOP_OF_PAGE = 'TOP-OF-PAGE'
I_CALLBACK_HTML_TOP_OF_PAGE = 'TOP-OF-PAGE'
I_CALLBACK_HTML_END_OF_LIST = ' '
I_STRUCTURE_NAME =
I_BACKGROUND_ID = ' '
I_GRID_TITLE =
I_GRID_SETTINGS =
is_layout = gd_layout
it_fieldcat = fieldcatalog[]
IT_EXCLUDING =
IT_SPECIAL_GROUPS =
it_sort = it_sort
IT_FILTER =
IS_SEL_HIDE =
I_DEFAULT = 'X'
I_SAVE = ' '
IS_VARIANT =
it_events = gt_events
IT_EVENT_EXIT =
IS_PRINT =
IS_REPREP_ID =
I_SCREEN_START_COLUMN = 0
I_SCREEN_START_LINE = 0
I_SCREEN_END_COLUMN = 0
I_SCREEN_END_LINE = 0
I_HTML_HEIGHT_TOP = 0
I_HTML_HEIGHT_END = 0
IT_ALV_GRAPHICS =
IT_HYPERLINK =
IT_ADD_FIELDCAT =
IT_EXCEPT_QINFO =
IR_SALV_FULLSCREEN_ADAPTER =
IMPORTING
E_EXIT_CAUSED_BY_CALLER =
ES_EXIT_CAUSED_BY_USER =
TABLES
t_outtab = it_main
EXCEPTIONS
PROGRAM_ERROR = 1
OTHERS = 2
IF sy-subrc <> 0.
MESSAGE ID SY-MSGID TYPE SY-MSGTY NUMBER SY-MSGNO
WITH SY-MSGV1 SY-MSGV2 SY-MSGV3 SY-MSGV4.
ENDIF.
ENDFORM. " display_alv
*& Form build_events
text
--> p1 text
<-- p2 text
FORM build_events .
DATA: is_event TYPE slis_alv_event.
break-point.
CALL FUNCTION 'REUSE_ALV_EVENTS_GET'
EXPORTING
i_list_type = 0
IMPORTING
et_events = gt_events[]
EXCEPTIONS
LIST_TYPE_WRONG = 1
OTHERS = 2
IF sy-subrc <> 0.
MESSAGE ID SY-MSGID TYPE SY-MSGTY NUMBER SY-MSGNO
WITH SY-MSGV1 SY-MSGV2 SY-MSGV3 SY-MSGV4.
ENDIF.
READ TABLE gt_events WITH KEY name = slis_ev_top_of_page INTO is_event.
IF sy-subrc = 0.
MOVE 'TOP_OF_PAGE' TO is_event-form.
MODIFY gt_events from is_event TRANSPORTING form WHERE name = slis_ev_top_of_page.
ENDIF.
ENDFORM. " build_events
*& Form top_of_page
text
--> p1 text
<-- p2 text
form top_of_page .
BREAK-POINT.
SKIP 3.
WRITE:/20 'BILLING DETAILS', 40 'PAYMENT DETAILS'.
endform. " top_of_page
Regards.
s.senthil kumarhi i modified ur program , check this and let me know
REPORT zsen_servicetax_gta NO STANDARD PAGE HEADING LINE-COUNT 100.
*****************************************TABLES USED**********************************************************************
TABLES: BSIS, "Accounting: Secondary Index for G/L Accounts
BSAS, "Accounting: Secondary Index for G/L Accounts (Cleared Items)
LFA1. "Vendor Master (General Section).
*****************************************WORK AREA / INTERNAL TABLE DECLARATION******************************************
TYPE-POOLS: slis.
TYPES: BEGIN OF ty_main,
hkont TYPE bsis-hkont,
belnr TYPE bsis-belnr,
budat TYPE bsis-budat,
blart TYPE bsis-blart,
dmbtr TYPE bsis-dmbtr,
xblnr TYPE bsis-xblnr,
shkzg TYPE bsis-shkzg,
augbl TYPE bsis-augbl,
kz_dmbtr TYPE bsis-dmbtr,
kz_xblnr TYPE bsis-xblnr,
kz_blart TYPE bsis-blart,
kz_belnr TYPE bsis-belnr,
kz_budat TYPE bsis-budat,
kz_zuonr TYPE bsis-zuonr,
name1 TYPE lfa1-name1,
slno TYPE i,
END OF ty_main,
BEGIN OF ty_bsas,
belnr TYPE bsas-hkont,
budat TYPE bsas-budat,
xblnr TYPE bsas-xblnr,
augbl TYPE bsas-augbl,
dmbtr TYPE bsas-dmbtr,
blart TYPE bsas-blart,
zuonr TYPE bsas-zuonr,
END OF ty_bsas.
DATA: it_main TYPE TABLE OF ty_main,
wa_main LIKE LINE OF it_main,
it_bsas TYPE TABLE OF ty_bsas,
wa_bsas LIKE LINE OF it_bsas.
DATA: it_sort TYPE slis_t_sortinfo_alv,
IT_fieldcatalog TYPE slis_t_fieldcat_alv ,
WA_fieldcatalog TYPE slis_fieldcat_alv,
gd_layout TYPE slis_layout_alv,
gt_events TYPE slis_t_event,
WA_EVENTS TYPE SLIS_T_EVENT,
int_fcat TYPE slis_fieldcat_alv,
it_header TYPE slis_t_listheader,
wa_header TYPE slis_listheader.
************************************************work variables***********************************************************************
DATA: ven_name TYPE lfa1-name1,
post_date TYPE bsis-budat,
t_tabix TYPE sy-tabix,
i_prg LIKE sy-repid.
***********************************************selection screen***********************************************************************
SELECTION-SCREEN: BEGIN OF BLOCK gtn WITH FRAME TITLE text-001 .
SELECT-OPTIONS: date FOR BSIS-BUDAT .
SELECTION-SCREEN: END OF BLOCK gtn.
************************************************data selection**************************************************************************
START-OF-SELECTION.
PERFORM data_retreval.
PERFORM build_catalog.
PERFORM layout.
PERFORM build_events.
PERFORM sortinfo.
IF it_main[] IS NOT INITIAL.
PERFORM display_alv.
ELSE.
MESSAGE 'No Records Matching For This Selection' TYPE 'E'.
ENDIF.
******************************data display*********************************************************************************************
**& Form data_retreval
*text
*--> p1 text
*<-- p2 text
FORM data_retreval .
CLEAR:it_main[], wa_main.
***********************************************selecting data from bsis table for the given date range**********************************
SELECT ahkont abelnr abudat ablart admbtr axblnr a~shkzg
b~augbl
INTO CORRESPONDING FIELDS OF TABLE it_main
FROM bsis AS a LEFT OUTER JOIN bsas AS b
ON abelnr = bbelnr
WHERE a~budat IN date.
*AND a~blart = 'KR'
*AND a~shkzg = 'S'
*AND a~hkont = '0002200530'.
***********************************************selecting data from bsas table using bsis-belnr*******************************************
LOOP AT it_main INTO wa_main.
SELECT belnr budat dmbtr xblnr zuonr augbl blart
INTO CORRESPONDING FIELDS OF wa_bsas
FROM bsas
WHERE belnr = wa_main-augbl
AND blart = 'KZ'.
ENDSELECT.
APPEND wa_bsas TO it_bsas.
ENDLOOP.
********************************************combining two tables data******************************************************************
LOOP AT it_main INTO wa_main.
t_tabix = sy-tabix.
wa_main-slno = t_tabix.
READ TABLE it_bsas INTO wa_bsas WITH KEY augbl = wa_main-augbl.
IF sy-subrc = 0.
SELECT SINGLE name1
FROM lfa1
INTO ven_name
WHERE lifnr = wa_bsas-zuonr.
wa_main-kz_dmbtr = wa_bsas-dmbtr.
wa_main-kz_belnr = wa_bsas-belnr.
wa_main-kz_blart = wa_bsas-blart.
wa_main-kz_budat = wa_bsas-budat.
wa_main-kz_xblnr = wa_bsas-xblnr.
wa_main-kz_zuonr = wa_bsas-zuonr.
wa_main-name1 = ven_name.
ENDIF.
MODIFY it_main FROM wa_main INDEX t_tabix TRANSPORTING kz_dmbtr kz_belnr kz_budat kz_blart kz_xblnr kz_zuonr name1 .
ENDLOOP.
SORT it_main BY kz_blart kz_zuonr.
LOOP AT it_main INTO wa_main.
wa_main-slno = sy-tabix.
MODIFY it_main FROM wa_main INDEX sy-tabix TRANSPORTING slno.
ENDLOOP.
ENDFORM. " data_retreval
**& Form build_catalog
*text
*--> p1 text
*<-- p2 text
FORM build_catalog .
DATA: col_pos TYPE i.
col_pos = col_pos + 1.
WA_fieldcatalog-fieldname = 'SLNO'.
WA_fieldcatalog-seltext_m = 'Serial No'.
WA_fieldcatalog-col_pos = col_pos.
APPEND WA_fieldcatalog TO IT_fieldcatalog.
CLEAR: WA_fieldcatalog.
col_pos = col_pos + 1.
WA_fieldcatalog-fieldname = 'KZ_ZUONR'.
WA_fieldcatalog-seltext_m = 'Vendor Num'.
WA_fieldcatalog-col_pos = col_pos.
APPEND WA_fieldcatalog TO IT_fieldcatalog.
CLEAR: WA_fieldcatalog.
col_pos = col_pos + 1.
WA_fieldcatalog-fieldname = 'NAME1'.
WA_fieldcatalog-seltext_m = 'Vendor Name'.
WA_fieldcatalog-col_pos = col_pos.
APPEND WA_fieldcatalog TO IT_fieldcatalog.
CLEAR: WA_fieldcatalog.
col_pos = col_pos + 1.
WA_fieldcatalog-fieldname = 'BLART'.
WA_fieldcatalog-seltext_m = 'BillDoc.Type'.
WA_fieldcatalog-col_pos = col_pos.
APPEND WA_fieldcatalog TO IT_fieldcatalog.
CLEAR: WA_fieldcatalog.
col_pos = col_pos + 1.
WA_fieldcatalog-fieldname = 'BELNR'.
WA_fieldcatalog-seltext_m = 'BillDoc.Num.'.
WA_fieldcatalog-col_pos = col_pos.
APPEND WA_fieldcatalog TO IT_fieldcatalog.
CLEAR: WA_fieldcatalog.
col_pos = col_pos + 1.
WA_fieldcatalog-fieldname = 'BUDAT'.
WA_fieldcatalog-seltext_m = 'BillPosting Date'.
WA_fieldcatalog-col_pos = col_pos.
APPEND WA_fieldcatalog TO IT_fieldcatalog.
CLEAR: WA_fieldcatalog.
col_pos = col_pos + 1.
WA_fieldcatalog-fieldname = 'XBLNR'.
WA_fieldcatalog-seltext_m = 'BillReference Num'.
WA_fieldcatalog-col_pos = col_pos.
APPEND WA_fieldcatalog TO IT_fieldcatalog.
CLEAR: WA_fieldcatalog.
col_pos = col_pos + 1.
WA_fieldcatalog-fieldname = 'DMBTR'.
WA_fieldcatalog-seltext_m = 'Bill Amount'.
WA_fieldcatalog-col_pos = col_pos.
WA_fieldcatalog-do_sum = 'X'.
APPEND WA_fieldcatalog TO IT_fieldcatalog.
CLEAR: WA_fieldcatalog.
col_pos = col_pos + 1.
WA_fieldcatalog-fieldname = 'KZ_BLART'.
WA_fieldcatalog-seltext_m = 'Pay_Doc.type'.
WA_fieldcatalog-col_pos = col_pos.
WA_fieldcatalog-do_sum = 'X'.
APPEND WA_fieldcatalog TO IT_fieldcatalog.
CLEAR: WA_fieldcatalog.
col_pos = col_pos + 1.
WA_fieldcatalog-fieldname = 'KZ_BELNR'.
WA_fieldcatalog-seltext_m = 'Pay_Document No'.
WA_fieldcatalog-col_pos = col_pos.
APPEND WA_fieldcatalog TO IT_fieldcatalog.
CLEAR: WA_fieldcatalog.
col_pos = col_pos + 1.
WA_fieldcatalog-fieldname = 'KZ_DMBTR'.
WA_fieldcatalog-seltext_m = 'Payment Amount'.
WA_fieldcatalog-col_pos = col_pos.
WA_fieldcatalog-do_sum = 'X'.
APPEND WA_fieldcatalog TO IT_fieldcatalog.
CLEAR: WA_fieldcatalog.
col_pos = col_pos + 1.
WA_fieldcatalog-fieldname = 'KZ_XBLNR'.
WA_fieldcatalog-seltext_m = 'Pay_Reference Num'.
WA_fieldcatalog-col_pos = col_pos.
APPEND WA_fieldcatalog TO IT_fieldcatalog.
CLEAR: WA_fieldcatalog.
col_pos = col_pos + 1.
WA_fieldcatalog-fieldname = 'KZ_BUDAT'.
WA_fieldcatalog-seltext_m = 'Pay_Posting Date'.
WA_fieldcatalog-col_pos = col_pos.
APPEND WA_fieldcatalog TO IT_fieldcatalog.
CLEAR: WA_fieldcatalog.
col_pos = col_pos + 1.
WA_fieldcatalog-fieldname = 'AUGBL'.
WA_fieldcatalog-seltext_m = 'Clr.Doc.Num'.
WA_fieldcatalog-col_pos = col_pos.
WA_fieldcatalog-row_pos = 2.
APPEND WA_fieldcatalog TO IT_fieldcatalog.
CLEAR: WA_fieldcatalog.
ENDFORM. " build_catalog
**& Form sortinfo
*text
*--> p1 text
*<-- p2 text
FORM sortinfo .
DATA: is_sort TYPE slis_sortinfo_alv.
CLEAR:is_sort.
is_sort-spos = 2.
is_sort-fieldname = 'KZ_ZUONR'.
is_sort-up = 'X'.
APPEND is_sort TO it_sort.
CLEAR: is_sort.
is_sort-spos = 1.
is_sort-fieldname = 'KZ_BLART'.
is_sort-up = 'X'.
is_sort-subtot = 'X'.
APPEND is_sort TO it_sort.
ENDFORM. " sortinfo
**& Form layout
*text
*--> p1 text
*<-- p2 text
FORM layout .
gd_layout-no_input = 'X'.
gd_layout-colwidth_optimize = 'X'.
gd_layout-zebra = 'X'.
*gd_layout-totals_text = 'Grand Total'.
*gd_layout-subtotals_text = 'BillBooked Not Paid'.
ENDFORM. " layout
**& Form display_alv
*text
*--> p1 text
*<-- p2 text
FORM display_alv .
i_prg = sy-repid.
DATA:it_events TYPE slis_t_event,
wa_events TYPE slis_alv_event.
WA_events-name = 'TOP_OF_PAGE'.
WA_events-form = 'TOP_OF_PAGE'.
APPEND wa_events TO it_events.
CALL FUNCTION 'REUSE_ALV_LIST_DISPLAY'
EXPORTING
*I_INTERFACE_CHECK = ' '
*I_BYPASSING_BUFFER = ' '
*I_BUFFER_ACTIVE = ' '
i_callback_program = 'I_PRG'
*I_CALLBACK_PF_STATUS_SET = ' '
*I_CALLBACK_USER_COMMAND = ' '
I_CALLBACK_TOP_OF_PAGE = 'TOP-OF-PAGE'
*I_CALLBACK_HTML_TOP_OF_PAGE = 'TOP-OF-PAGE'
*I_CALLBACK_HTML_END_OF_LIST = ' '
*I_STRUCTURE_NAME =
*I_BACKGROUND_ID = ' '
*I_GRID_TITLE =
*I_GRID_SETTINGS =
is_layout = gd_layout
it_fieldcat = IT_fieldcatalog[]
*IT_EXCLUDING =
*IT_SPECIAL_GROUPS =
*it_sort = it_sort
*IT_FILTER =
*IS_SEL_HIDE =
*I_DEFAULT = 'X'
*I_SAVE = ' '
*IS_VARIANT =
it_events = It_events.
*IT_EVENT_EXIT =
*IS_PRINT =
*IS_REPREP_ID =
*I_SCREEN_START_COLUMN = 0
*I_SCREEN_START_LINE = 0
*I_SCREEN_END_COLUMN = 0
*I_SCREEN_END_LINE = 0
*I_HTML_HEIGHT_TOP = 0
*I_HTML_HEIGHT_END = 0
*IT_ALV_GRAPHICS =
*IT_HYPERLINK =
*IT_ADD_FIELDCAT =
*IT_EXCEPT_QINFO =
*IR_SALV_FULLSCREEN_ADAPTER =
*IMPORTING
*E_EXIT_CAUSED_BY_CALLER =
*ES_EXIT_CAUSED_BY_USER =
*TABLES
*t_outtab = it_main
*EXCEPTIONS
*PROGRAM_ERROR = 1
*OTHERS = 2
*IF sy-subrc <> 0.
*MESSAGE ID SY-MSGID TYPE SY-MSGTY NUMBER SY-MSGNO
*WITH SY-MSGV1 SY-MSGV2 SY-MSGV3 SY-MSGV4.
*ENDIF.
ENDFORM. " display_alv
**& Form build_events
*text
*--> p1 text
*<-- p2 text
FORM build_events .
DATA: is_event TYPE slis_alv_event.
CALL FUNCTION 'REUSE_ALV_EVENTS_GET'
EXPORTING
i_list_type = 0
IMPORTING
et_events = gt_events[]
EXCEPTIONS
LIST_TYPE_WRONG = 1
OTHERS = 2
IF sy-subrc NE 0.
MESSAGE ID SY-MSGID TYPE SY-MSGTY NUMBER SY-MSGNO
WITH SY-MSGV1 SY-MSGV2 SY-MSGV3 SY-MSGV4.
ENDIF.
READ TABLE gt_events WITH KEY name = slis_ev_top_of_page INTO is_event.
IF sy-subrc = 0.
MOVE 'TOP_OF_PAGE' TO is_event-form.
MODIFY gt_events from is_event TRANSPORTING form WHERE name = slis_ev_top_of_page.
ENDIF.
ENDFORM. " build_events
**& Form top_of_page
*text
*--> p1 text
*<-- p2 text
form top_of_page .
SKIP 3.
WRITE:/20 'BILLING DETAILS', 40 'PAYMENT DETAILS'.
ENDFORM.
reward points if useful,
venkat. -
Dear SDN,
I have created a Workflow and i am triggering through an event . For this have created ZEvent in ZBOR(Modified from Std. APPR_DOC)and attached the zevent in my screen (HR related template PHAP_CATLOG_PA) through oohap_basic.When I run in Background everything is working fine.But when I run through the Tcode(PHAP_CATLOG_PA). event itself not triggering.Problem is my event is not firing.When I check in SWEL my zevent is showing std BOR.My zevent is not catching my ZBOR.Can anyone help me out with this issue.
Regards,
Gopi.Hi,
gopi BOR will always show the standard BOR and you can put a start condition based on that condition.
after that in first activity you can use your custom BOR and it's methods.
Hope magic Works!
Regards,
Purvesh Patel. -
BSEG.CREATED event not triggering when a document is posted in FB60
Hi All,
I have a requirement in which i need to post documents in FB60/FB65/FB01 tcode. But when i post the document in FB60 the event BSEG.CREATED is not triggering. I could not see any trace in SWEL. But when i park the document in FB60, FIPP.CREATED event is getting triggerd.
Can anyone tell me why this BSEG.CREATED event is not triggering.
Thanking you in advance,
satheesh.Hi Viji,
Thanks for your quick reply.
We have maintained the required configurations in the system related to this. But still the event BSEG.CREATED is not triggering.
for this the alternative solution is to implement the BTE '1030'. But our functional team is asking us to check whey standard business object BSEG.CREATED is not triggering when we post a document. So that particular reason we are not able to find out.
Configuration maintained.
1) Created a workflow variant and assigned it to particular company code(OBWA and OBWJ).
2) Checked the 'Posting' release' and 'Release payments' checkboxes in the OBWA transaction.
3) Event linkage for BSEG is active.(SWETYPV)
Thanks,
satheesh -
End of Page event not triggering in ALV report
Hello,
I am developing an ALV report using REUSE_ALV_LIST_DISPLAY. Whatever I write in top_of_page, it will be displayed in the header portion of the output.
But I want to display some footer text at the end of the page. The problem I am facing is, the WRITE statements within end_of_page are not displayed when the report is run.
I have populated the i_events as follows :
FORM f_events CHANGING p_i_events TYPE slis_t_event.
CONSTANTS : l_c_top_of_page TYPE slis_formname VALUE 'TOP_OF_PAGE',
l_c_end_of_page TYPE slis_formname VALUE 'END_OF_PAGE'.
DATA : l_wa_event TYPE slis_alv_event.
Returns table of possible events
CALL FUNCTION 'REUSE_ALV_EVENTS_GET'
EXPORTING
i_list_type = 0
IMPORTING
et_events = p_i_events.
To append internal table holding event names with event 'TOP OF PAGE'
READ TABLE p_i_events INTO l_wa_event
WITH KEY name = slis_ev_top_of_page.
IF sy-subrc = 0.
MOVE l_c_top_of_page TO l_wa_event-form.
APPEND l_wa_event TO p_i_events.
ENDIF.
To append internal table holding event names with event 'END OF PAGE'
READ TABLE p_i_events INTO l_wa_event
WITH KEY name = slis_ev_end_of_page.
IF sy-subrc = 0.
MOVE l_c_end_of_page TO l_wa_event-form.
APPEND l_wa_event TO p_i_events.
ENDIF.
ENDFORM. "f_events
Regds
RajeshHi have a look at the following code, and change ur code for end of page accordingly. this will resolve ur problem.
This is a basic ALV with the followings:-
- Page Heading
- Page No
- Sub-Total
- Grand Total
REPORT ZALV.
TYPE-POOLS: SLIS.
DATA: G_REPID LIKE SY-REPID,
GS_PRINT TYPE SLIS_PRINT_ALV,
GT_LIST_TOP_OF_PAGE TYPE SLIS_T_LISTHEADER,
GT_EVENTS TYPE SLIS_T_EVENT,
GT_SORT TYPE SLIS_T_SORTINFO_ALV,
GS_LAYOUT TYPE SLIS_LAYOUT_ALV,
GT_FIELDCAT TYPE SLIS_T_FIELDCAT_ALV,
FIELDCAT_LN LIKE LINE OF GT_FIELDCAT,
COL_POS TYPE I.
DATA: BEGIN OF ITAB,
FIELD1(5) TYPE C,
FIELD2(5) TYPE C,
FIELD3(5) TYPE P DECIMALS 2,
END OF ITAB.
DATA: BEGIN OF ITAB1 OCCURS 0.
INCLUDE STRUCTURE ITAB.
DATA: END OF ITAB1.
DATA: BEGIN OF ITAB_FIELDCAT OCCURS 0.
INCLUDE STRUCTURE ITAB.
DATA: END OF ITAB_FIELDCAT.
Print Parameters
PARAMETERS:
P_PRINT AS CHECKBOX DEFAULT ' ', "PRINT IMMEDIATE
P_NOSINF AS CHECKBOX DEFAULT 'X', "NO SELECTION INFO
P_NOCOVE AS CHECKBOX DEFAULT ' ', "NO COVER PAGE
P_NONEWP AS CHECKBOX DEFAULT ' ', "NO NEW PAGE
P_NOLINF AS CHECKBOX DEFAULT 'X', "NO PRINT LIST INFO
P_RESERV TYPE I. "NO OF FOOTER LINE
INITIALIZATION.
G_REPID = SY-REPID.
PERFORM PRINT_BUILD USING GS_PRINT. "Print PARAMETERS
START-OF-SELECTION.
TEST DATA
MOVE 'TEST1' TO ITAB1-FIELD1.
MOVE 'TEST1' TO ITAB1-FIELD2.
MOVE '10.00' TO ITAB1-FIELD3.
APPEND ITAB1.
MOVE 'TEST2' TO ITAB1-FIELD1.
MOVE 'TEST2' TO ITAB1-FIELD2.
MOVE '20.00' TO ITAB1-FIELD3.
APPEND ITAB1.
DO 50 TIMES.
APPEND ITAB1.
ENDDO.
END-OF-SELECTION.
PERFORM BUILD.
PERFORM EVENTTAB_BUILD CHANGING GT_EVENTS.
PERFORM COMMENT_BUILD CHANGING GT_LIST_TOP_OF_PAGE.
PERFORM CALL_ALV.
FORM BUILD.
DATA FIELD CATALOG
Explain Field Description to ALV
DATA: FIELDCAT_IN TYPE SLIS_FIELDCAT_ALV.
CLEAR FIELDCAT_IN.
FIELDCAT_LN-FIELDNAME = 'FIELD1'.
FIELDCAT_LN-TABNAME = 'ITAB1'.
*FIELDCAT_LN-NO_OUT = 'X'. "FIELD NOT DISPLAY, CHOOSE FROM LAYOUT
FIELDCAT_LN-KEY = ' '. "SUBTOTAL KEY
FIELDCAT_LN-NO_OUT = ' '.
FIELDCAT_LN-SELTEXT_L = 'HEAD1'.
APPEND FIELDCAT_LN TO GT_FIELDCAT.
CLEAR FIELDCAT_IN.
FIELDCAT_LN-FIELDNAME = 'FIELD2'.
FIELDCAT_LN-TABNAME = 'ITAB1'.
FIELDCAT_LN-NO_OUT = 'X'.
FIELDCAT_LN-SELTEXT_L = 'HEAD2'.
APPEND FIELDCAT_LN TO GT_FIELDCAT.
CLEAR FIELDCAT_IN.
FIELDCAT_LN-FIELDNAME = 'FIELD3'.
FIELDCAT_LN-TABNAME = 'ITAB1'.
FIELDCAT_LN-REF_FIELDNAME = 'MENGE'. "<- REF FIELD IN THE DICTIONNARY
FIELDCAT_LN-REF_TABNAME = 'MSEG'. "<- REF TABLE IN THE DICTIONNARY
FIELDCAT_LN-NO_OUT = ' '.
FIELDCAT_LN-DO_SUM = 'X'. "SUM UPON DISPLAY
APPEND FIELDCAT_LN TO GT_FIELDCAT.
DATA SORTING AND SUBTOTAL
DATA: GS_SORT TYPE SLIS_SORTINFO_ALV.
CLEAR GS_SORT.
GS_SORT-FIELDNAME = 'FIELD1'.
GS_SORT-SPOS = 1.
GS_SORT-UP = 'X'.
GS_SORT-SUBTOT = 'X'.
APPEND GS_SORT TO GT_SORT.
CLEAR GS_SORT.
GS_SORT-FIELDNAME = 'FIELD2'.
GS_SORT-SPOS = 2.
GS_SORT-UP = 'X'.
*GS_SORT-SUBTOT = 'X'.
APPEND GS_SORT TO GT_SORT.
ENDFORM.
FORM CALL_ALV.
ABAP List Viewer
CALL FUNCTION 'REUSE_ALV_LIST_DISPLAY'
EXPORTING
I_INTERFACE_CHECK = ' '
I_BYPASSING_BUFFER =
I_BUFFER_ACTIVE = ' '
I_CALLBACK_PROGRAM = G_REPID
I_CALLBACK_PF_STATUS_SET = ' '
I_CALLBACK_USER_COMMAND = ' '
I_STRUCTURE_NAME = 'ITAB1'
IS_LAYOUT = GS_LAYOUT
IT_FIELDCAT = GT_FIELDCAT[]
IT_EXCLUDING =
IT_SPECIAL_GROUPS =
IT_SORT = GT_SORT[]
IT_FILTER =
IS_SEL_HIDE =
I_DEFAULT = 'X'
I_SAVE = ' '
IS_VARIANT =
IT_EVENTS = GT_EVENTS[]
IT_EVENT_EXIT =
IS_PRINT = GS_PRINT
IS_REPREP_ID =
I_SCREEN_START_COLUMN = 0
I_SCREEN_START_LINE = 0
I_SCREEN_END_COLUMN = 0
I_SCREEN_END_LINE = 0
IMPORTING
E_EXIT_CAUSED_BY_CALLER =
ES_EXIT_CAUSED_BY_USER =
TABLES
T_OUTTAB = ITAB1
EXCEPTIONS
PROGRAM_ERROR = 1
OTHERS = 2.
ENDFORM.
HEADER FORM
FORM EVENTTAB_BUILD CHANGING LT_EVENTS TYPE SLIS_T_EVENT.
CONSTANTS:
GC_FORMNAME_TOP_OF_PAGE TYPE SLIS_FORMNAME VALUE 'TOP_OF_PAGE'.
*GC_FORMNAME_END_OF_PAGE TYPE SLIS_FORMNAME VALUE 'END_OF_PAGE'.
DATA: LS_EVENT TYPE SLIS_ALV_EVENT.
CALL FUNCTION 'REUSE_ALV_EVENTS_GET'
EXPORTING
I_LIST_TYPE = 0
IMPORTING
ET_EVENTS = LT_EVENTS.
READ TABLE LT_EVENTS WITH KEY NAME = SLIS_EV_TOP_OF_PAGE
INTO LS_EVENT.
IF SY-SUBRC = 0.
MOVE GC_FORMNAME_TOP_OF_PAGE TO LS_EVENT-FORM.
APPEND LS_EVENT TO LT_EVENTS.
ENDIF.
define END_OF_PAGE event
READ TABLE LT_EVENTS WITH KEY NAME = SLIS_EV_END_OF_PAGE
INTO LS_EVENT.
IF SY-SUBRC = 0.
MOVE GC_FORMNAME_END_OF_PAGE TO LS_EVENT-FORM.
APPEND LS_EVENT TO LT_EVENTS.
ENDIF.
ENDFORM.
FORM COMMENT_BUILD CHANGING GT_TOP_OF_PAGE TYPE SLIS_T_LISTHEADER.
DATA: GS_LINE TYPE SLIS_LISTHEADER.
CLEAR GS_LINE.
GS_LINE-TYP = 'H'.
GS_LINE-INFO = 'HEADER 1'.
APPEND GS_LINE TO GT_TOP_OF_PAGE.
CLEAR GS_LINE.
GS_LINE-TYP = 'S'.
GS_LINE-KEY = 'STATUS 1'.
GS_LINE-INFO = 'INFO 1'.
APPEND GS_LINE TO GT_TOP_OF_PAGE.
GS_LINE-KEY = 'STATUS 2'.
GS_LINE-INFO = 'INFO 2'.
APPEND GS_LINE TO GT_TOP_OF_PAGE.
CLEAR GS_LINE.
GS_LINE-TYP = 'A'.
GS_LINE-INFO = 'ACTION'.
APPEND GS_LINE TO GT_TOP_OF_PAGE.
ENDFORM.
FORM TOP_OF_PAGE.
CALL FUNCTION 'REUSE_ALV_COMMENTARY_WRITE'
EXPORTING
IT_LIST_COMMENTARY = GT_LIST_TOP_OF_PAGE.
WRITE: SY-DATUM, 'Page No', SY-PAGNO LEFT-JUSTIFIED.
ENDFORM.
FORM END_OF_PAGE.
WRITE at (sy-linsz) sy-pagno CENTERED.
ENDFORM.
PRINT SETTINGS
FORM PRINT_BUILD USING LS_PRINT TYPE SLIS_PRINT_ALV.
LS_PRINT-PRINT = P_PRINT. "PRINT IMMEDIATE
LS_PRINT-NO_PRINT_SELINFOS = P_NOSINF. "NO SELECTION INFO
LS_PRINT-NO_COVERPAGE = P_NOCOVE. "NO COVER PAGE
LS_PRINT-NO_NEW_PAGE = P_NONEWP.
LS_PRINT-NO_PRINT_LISTINFOS = P_NOLINF. "NO PRINT LIST INFO
LS_PRINT-RESERVE_LINES = P_RESERV.
ENDFORM.
*END OF ZALV PROGRAM
Satish -
OnEnter event not triggering in standard WD
HI Experts,
I am creating a view enhancement in standard WD component. I have craeted an action for Onenter event for an input field.
When i press enter after selecting that field, the action is not triggered and hence my event handler method is not executing.
Please let me know the reason why it is not happening and how can i fix it.
Thanks & Regards,
Sushant SinghI dont think if you change the properties of UI elements which are standard will work.
If already OnEnter is created for input field then you can create Post-Exit , Pre-Exit methods.
Alternative would be to make the Standard Input field as invisible and create you own input field with same properties as of standard one. -
Hi All,
I am using ALV GRID in object oriented with editing option.If user made any changes in the Grid ,then i will captured the changes by the event DATA_CHANGED and i will display the error message inside the DATA_CHANGED event method using Method ADD_PROTOCOL_ENTRY and DISPLAY_PROTOCOL(which displayed a message in popup window with the field name ,row etc.).
The Method CHECK_CHANGED_DATA in PAI will trigger DATA_CHANGE event.It is some time triggering DATA_CHANGED and some time it is not triggering DATA_CHANGED event..Why it is not triggering DATA_CHANGED event?
Can any one give me solution for this.....
Thanks in Advance..Hi,
i have to register an ENTER event:
that is
CALL METHOD alv->register_edit_event
EXPORTING
i_event_id = cl_gui_alv_grid=>mc_evt_enter.
For this also it is not triggering...
Maybe you are looking for
-
This is my first time posting on this fourm. I have a 2011 Imac which came installed with snow leopard. since then i have upgraded to lion and then mountain lion. I think the problem began after upgrading to lion , but its been a while and im not re
-
is it possiple to send a signal to both outputs at the same time
-
Delete entries from internal table
Hello friends, I have a screen on which im displaying a table, now i have also provided an delete button which deletes the selected record. the record which i have written is GET CURSOR FIELD FLD LINE IND. READ
-
HT1320 ipod not showing up on computer in i tunes
hi my i pod classicn has died and is showing the red cross on the screen. tried to reset nothing happens pluged it into computer and nothing shows up HELP!!!!!
-
90% of pictures disappeared after adding Maverick. My Time Machine folders were in the right order but mostly empty so useless for restore. Repair and rebuild attempts were not effective. Downloaded my Carbonite file which is now sitting on my deskto