We have added search box. Key in SAP issue keyword to search
TopBottom

Announcement: wanna exchange links? contact me at sapchatroom@gmail.com.

RE:[sap-dev] Table Control Loop in PAI

Posted by Admin at
Share this post:
Ma.gnolia DiggIt! Del.icio.us Yahoo Furl Technorati Reddit

Reply from TrishDV on Dec 5 at 9:15 AM
John,

I have run this code thru debug multiple times, so much that I see it when I close my eyes. There is data in the internal table, 8 records, 4 lines visible on the screen. The code processes the LOOP AT and then drops to the ENDLOOP 4 times and then moves on to the next MODULE in the PAI. It's like I have no MODULES or FIELDS in the LOOP...ENDLOOP. But as you can see, I do. The table control on the screen is TC_PERS. I double checked that and the field names that I am using. I made sure all the MODULES exist and have no trouble activating. I am truly baffled. I have used table controls before. This screen is a subscreen and all the others were main screens but I don't understand why that would make a difference.

Ameen,

The code enters PAI no problem. It processes all MODULES before and after the loop. It processes the loop the correct number of times, it just never enters the loop.

Thanks for your thoughts. I'll take all the help I can get.

Trish

---------------Original Message---------------
From: Trisha DeVrieze
Sent: Friday, November 30, 2012 12:45 PM
Subject: Table Control Loop in PAI

In PAI, I have the table control loop, with data, and it does the looping but never enters the loop. So it gets to the LOOP AT scroll_tab and goes right to the ENDLOOP. In between there is a MODULE and then a CHAIN statement with FIELDS and MODULES. The screen allows for 3 entries so it goes to LOOP AT ... ENDLOOP 3 times and moves on. Any ideas why it doesn't enter the loop? It falls into the PBO loop no problem.

PROCESS BEFORE OUTPUT.
MODULE trans_init.

LOOP AT scroll_tab WITH CONTROL tc_pers
CURSOR scroll-cursor.
MODULE lst_sys_col.
MODULE get_entry_afrud.
MODULE set_cursor.
ENDLOOP.


PROCESS AFTER INPUT.
*--------------------- Processing after entering ------------------
MODULE processing_exit AT EXIT-COMMAND.
MODULE save_ok_code.
MODULE get_cursor_line.

LOOP AT scroll_tab.

* Provide confirmation data from table
MODULE get_conf_from_table.

CHAIN.
FIELD: afru_col-selkz,
afrud-pernr,
afrud-ismnw_2.

MODULE get_aufnr_from_cmfu ON CHAIN-REQUEST.

MODULE afvgd_set.
FIELD: afrud-ismnw_2
MODULE request_ismnw ON REQUEST.
FIELD: afrud-ismnw_2
MODULE reset_vbkz ON REQUEST.

MODULE get_conf_col.
MODULE check_conf_col ON CHAIN-REQUEST.
MODULE check_conf_col_save.

ENDCHAIN.

CHAIN.
FIELD: afrud-ismnw_2
MODULE check_kum_arbeit ON CHAIN-REQUEST.
ENDCHAIN.

MODULE reset_request.

ENDLOOP.

 
Reply to this email to post your response.
 
__.____._
Manage Settings | Unsubscribe | Create FAQ | Send Feedback
  
Copyright © 2012 Ziff Davis, Inc. and message author.
Ziff Davis, Inc. 28 E 28th Street New York, NY 10016
TrishDV  

Programmer Analyst
 
Mark as helpful
View this online
Ask a new question
 
In the Spotlight
Earn Recognition for Your Contributions at Toolbox for IT. Gain Points for Community Achievements

_.____.__

0 comments:

Post a Comment

T r a n s l a t e to your language