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

ALV Grid Help

Former Member
0 Likes
776

I am kind of new to ABAP programming. Can someone help me by telling me hot to copy a GUI status from an existing SAP program into my program? I also have one input field on the grid and I after updating that field when the user exits I need to read all of the records that have been updated and then update the database with those records. Any help will be greatly appreciated.

Thanks

1 ACCEPTED SOLUTION
Read only

Former Member
0 Likes
581

proceed in the following lines...

CALL FUNCTION 'REUSE_ALV_GRID_DISPLAY'

EXPORTING

I_CALLBACK_PROGRAM = W_REPID

I_CALLBACK_PF_STATUS_SET = 'PF_STATUS'

I_CALLBACK_USER_COMMAND = 'USER_COMMAND'

FORM USER_COMMAND USING P_UCOMM TYPE SY-UCOMM

P_SELFLD TYPE SLIS_SELFIELD.

case p_ucomm.

when 'SAVE'.

Data ref1 type ref to cl_gui_alv_grid.

CALL FUNCTION 'GET_GLOBALS_FROM_SLVC_FULLSCR'

IMPORTING

E_GRID = ref1.

call method ref1->check_changed_data

modify ztable from table itab.

endcase.

ENDFORM.

Regards,

ravi

I am kind of new to ABAP programming. Can someone help me by telling me hot to copy a GUI status from an existing SAP program into my program? I also have one input field on the grid and I after updating that field when the user exits I need to read all of the records that have been updated and then update the database with those records. Any help will be greatly appreciated.

Thanks

3 REPLIES 3
Read only

RichHeilman
Developer Advocate
Developer Advocate
0 Likes
581

You may copy the gui status using the SE41 transaction. Click the "Copy Status" Button on the application toolbar.

For editable ALV grid, please check sample programs BCALV_EDIT*

Regards,

Rich Heilman

Read only

Former Member
0 Likes
582

proceed in the following lines...

CALL FUNCTION 'REUSE_ALV_GRID_DISPLAY'

EXPORTING

I_CALLBACK_PROGRAM = W_REPID

I_CALLBACK_PF_STATUS_SET = 'PF_STATUS'

I_CALLBACK_USER_COMMAND = 'USER_COMMAND'

FORM USER_COMMAND USING P_UCOMM TYPE SY-UCOMM

P_SELFLD TYPE SLIS_SELFIELD.

case p_ucomm.

when 'SAVE'.

Data ref1 type ref to cl_gui_alv_grid.

CALL FUNCTION 'GET_GLOBALS_FROM_SLVC_FULLSCR'

IMPORTING

E_GRID = ref1.

call method ref1->check_changed_data

modify ztable from table itab.

endcase.

ENDFORM.

Regards,

ravi

Read only

Former Member
0 Likes
581

Hi,

Have a look at these good links-

<b>ALV GRID</b>

<b>ALV all Imp</b>

http://www.geocities.com/mpioud/Abap_programs.html

http://www.sapdevelopment.co.uk/reporting/alvhome.htm

http://www.sapdevelopment.co.uk/reporting/alv/alvgrid_events.htm

<b>ALVGRID with refresh</b>

http://www.geocities.com/mpioud/Z_DEMO_ALV_REFRESH_BUTTON.html

<b>ALV Group Heading</b>

http://www.sap-img.com/fu037.htm

http://www.sap-img.com/abap/test-alv-display-with-header-footer.htm

http://www.sap-img.com/abap/sample-alv-heading-in-alv.htm

<b>ALV Documentation for Field</b>

http://www.mpls.k12.mn.us/sites/f7071225-9844-4da6-96c0-996b9c74b221/uploads/SAP_Navigation_Training...

http://www.geocities.com/mpioud/Z_ALV_CELL_COLOR.html

http://www.sap-img.com/abap/line-color-in-alv-example.htm

http://www.sapdevelopment.co.uk/reporting/alv/alvgrid_color.htm

<b>1. Please give me general info on ALV.</b>

http://www.sapfans.com/forums/viewtopic.php?t=58286

http://www.sapfans.com/forums/viewtopic.php?t=76490

http://www.sapfans.com/forums/viewtopic.php?t=20591

http://www.sapfans.com/forums/viewtopic.php?t=66305 - <b>this one discusses which way should you use - ABAP Objects calls or simple function modules.</b>

<b>2. How do I program double click in ALV?</b>

http://www.sapfans.com/forums/viewtopic.php?t=11601

http://www.sapfans.com/forums/viewtopic.php?t=23010

<b>3. How do I add subtotals (I have problem to add them)...</b>

http://www.sapfans.com/forums/viewtopic.php?t=20386

http://www.sapfans.com/forums/viewtopic.php?t=85191

http://www.sapfans.com/forums/viewtopic.php?t=88401

http://www.sapfans.com/forums/viewtopic.php?t=17335

<b>4. How to add list heading like top-of-page in ABAP lists?</b>

http://www.sapfans.com/forums/viewtopic.php?t=58775

http://www.sapfans.com/forums/viewtopic.php?t=60550

http://www.sapfans.com/forums/viewtopic.php?t=16629

<b>5. How to print page number / total number of pages X/XX in ALV?</b>

http://www.sapfans.com/forums/viewtopic.php?t=29597 (no direct solution)

<b>6. ALV printing problems. The favourite is: The first page shows the number of records selected but I don't need this.</b>

http://www.sapfans.com/forums/viewtopic.php?t=64320

http://www.sapfans.com/forums/viewtopic.php?t=44477

<b>7. How can I set the cell color in ALV?</b>

http://www.sapfans.com/forums/viewtopic.php?t=52107

<b>8. How do I print a logo/graphics in ALV?</b>

http://www.sapfans.com/forums/viewtopic.php?t=81149

http://www.sapfans.com/forums/viewtopic.php?t=35498

http://www.sapfans.com/forums/viewtopic.php?t=5013

<b>9. How do I create and use input-enabled fields in ALV?</b>

http://www.sapfans.com/forums/viewtopic.php?t=84933

http://www.sapfans.com/forums/viewtopic.php?t=69878

<b>10. How can I use ALV for reports that are going to be run in background?</b>

http://www.sapfans.com/forums/viewtopic.php?t=83243

http://www.sapfans.com/forums/viewtopic.php?t=19224

<b>11. How can I display an icon in ALV? (Common requirement is traffic light icon).</b>

http://www.sapfans.com/forums/viewtopic.php?t=79424

http://www.sapfans.com/forums/viewtopic.php?t=24512

<b>12. How can I display a checkbox in ALV?</b>

http://www.sapfans.com/forums/viewtopic.php?t=88376

http://www.sapfans.com/forums/viewtopic.php?t=40968

http://www.sapfans.com/forums/viewtopic.php?t=6919

<b>For language setting and decimal separator</b>

/people/horst.keller/blog/2004/11/16/abap-geek-7-150-babylonian-confusion

<b>User Exits</b>

http://www.sap-img.com/abap/a-short-tutorial-on-user-exits.htm

http://www.sapgenie.com/abap/code/abap26.htm

http://www.sap-img.com/abap/what-is-user-exits.htm

http://wiki.ittoolbox.com/index.php/HOWTO:Implement_a_screen_exit_to_a_standard_SAP_transaction

http://www.easymarketplace.de/userexit.php

http://www.sap-img.com/abap/a-short-tutorial-on-user-exits.htm

http://www.sappoint.com/abap/userexit.pdfUser-Exit

<b>Please Reward Points & Mark Helpful Answers</b>

To mark Helpful Answers ;click radio Button next to the post.

RadioButtons

<b>o</b> Helpful Answer

<b>o</b> Very helpful Answer

<b>o</b> Problem Solved.

Click any of the above button next to the post; as per the anwers

<b>To close the thread; Click Probelm solved Radio Button next to the post , which u feel is best possible answers</b>

Regards,

Tanuja.