Application Development and Automation Discussions
Join the discussions or start your own on all things application development, including tools and APIs, programming models, and keeping your skills sharp.
cancel
Showing results for 
Search instead for 
Did you mean: 
Read only

EVENT problem in Table maintenance generator

Former Member
0 Likes
1,725

Hello all

I m working on 4.6C sytem. I m facing 2 problems in events in table maintenance generator

(1) I am using 04 event (After deleting records from table) I have written BREAK-POINT in the Form .....ENDFORM... But the control doesnt stop there , when i select an existing record and press delete record button? not able to understand this

(2) When i implement even t 03( Before deleting records from table) , and select an existing record and press delete record button . Control successfully Go to corresponding FORM ... BREAK-POINT ENDFORM .

But now the problem is.. in debuggin i can see the contents in TOTAL table but when i try to code LOOP at TOTAL ..ENDLOOP...it gives me syntax error saying " table TOTAL doesnot exists or not defined..but similar field TOTAL_S , TOTAL_M , TOTAL_L exists.. ???

how come i can see the same during debugging but cannot code it ?

Plese help

Nilesh

1 ACCEPTED SOLUTION
Read only

danilo_henriques
Explorer
0 Likes
1,077

Hi Nilesh,

(1) I think the control will stop there after you delete AND save. Not sure about that but give it a try.

(2) I believe you are trying to access fields inside table TOTAL, is that right?

Actually you have to declare a work area with your Z table type.

DATA: w_workarea type ztable.


LOOP at total.
  w_workarea = total.

endoop.

Then you can work with w_workarea.

Best regards.

Hi Nilesh,

(1) I think the control will stop there after you delete AND save. Not sure about that but give it a try.

(2) I believe you are trying to access fields inside table TOTAL, is that right?

Actually you have to declare a work area with your Z table type.

DATA: w_workarea type ztable.


LOOP at total.
  w_workarea = total.

endoop.

Then you can work with w_workarea.

Best regards.

5 REPLIES 5
Read only

danilo_henriques
Explorer
0 Likes
1,078

Hi Nilesh,

(1) I think the control will stop there after you delete AND save. Not sure about that but give it a try.

(2) I believe you are trying to access fields inside table TOTAL, is that right?

Actually you have to declare a work area with your Z table type.

DATA: w_workarea type ztable.


LOOP at total.
  w_workarea = total.

endoop.

Then you can work with w_workarea.

Best regards.

Read only

0 Likes
1,077

Hello danilo,

I had tried it , but after pressing SAVE also it DID NOT stop there. and it just deleted the entries.

also

i DID NOT declare work area for my table BUT before that IF i simply write LOOP AT TOTAL ...ENDLOOP still it gives me the same syntax error..

Nilesh

Read only

0 Likes
1,077

Hi Nilesh,

Check the link given by Danilo.

http://help.sap.com/saphelp_nw04/helpdata/en/91/ca9f14a9d111d1a5690000e82deaaa/content.htm

Only those structures will be available for coding, which is given under 'Realization' heading in that link.

TOTAL itab will not be available in 03 & 04 events. You can use EXTRACT.

Thanks,

Nisha Vengal.

Read only

0 Likes
1,077

Hello Nisha & Danilo

Thanks a lot. I have not used EXTRACT in coding. I will try it ..BUT in the documentation of events from SAP i read that Both TOTAL and EXTRACT tables should be modified . So i had started coding with TOTAL and got stuck..

anyways i will check and revert back

Thanks once again.

Best regards

Nilesh