Doppelklick im Table Control

Today one of the member of our telegram group aked how to open a document in it’s related transaction by doubleclicking the documentnumber in a tablecontrol. So I created a small demo report to open a material by doubleclicking on materialnumber.

Create a report in SE38 or SE80 and copy the following code into it.

Create a screen 100 and copy the following code into flow logic of the screen.

Create PF-Status 0100 as shown below.

Important for the doubleclick is funktioncode 4.

Create title 0100 as shown below.

Now place the tablecontrol on screen 100 as described below.

1. Use normal tablecontrol and not tablecontrol wizard.
2. Fill the screen with the tablecontrol object
1. Open the Dictionary/Program Fields Window
2. Enter the tablename „MARA“
3. click Get From Dictionary
4. Choose the fields
5. Confirm with OK
Place the selected fields in the grey area at top of the tablecontrol.
1. Doubleclick on every field directly under the header
2. Uncheck Input Field for all fields
1. Check Responds to double-click for the first column in tablecontrol.

Now activate all created objects and execute the report.

Doubleclick one Material in Column Material.
See that