Suchhilfe

Alles rund um die Sprache ABAP®: Funktionsbausteine, Listen, ALV
4 Beiträge • Seite 1 von 1
4 Beiträge Seite 1 von 1

Suchhilfe

Beitrag von moin (ForumUser / 4 / 0 / 0 ) »
Hallo Zusammen,

ich muss ein Attribut einer Suchhilfe von Anzeigefeld auf Eingabefeld ändern. Normalerweise wird dieses in der Suchhilfe mit dem Attribut SANZ gelöst. Bei dieser Suchhilfe ist das Attribut SANZ zum Feld aber nicht gesetzt und trotzdem ist es nur ein Anzeigefeld. Weiss jemand, wie dieses realisert wurde? Die Suchhilfe liegt im Kundennamensraum.

gesponsert
Stellenangebote auf ABAPforum.com schalten
kostenfrei für Ausbildungsberufe und Werksstudenten


Suchhilfe Exit ?

Beitrag von Kleenmex (Specialist / 126 / 0 / 0 ) »
Hast du ein Suchhilfe-Exit drin? SE11 Suchhilfe XXXX und dann Suchhilfe-Exit ...?!
Gruss

Kleenmex

Re: Suchhilfe Exit ?

Beitrag von moin (ForumUser / 4 / 0 / 0 ) »
Suchhileexit ist drin, allerdings hat das Feld in shlp-interface bereits das Attribut "Nur Anzeigefeld":

FUNCTION z_bw_f4_uebung_exit.

*"----------------------------------------------------------------------

*"*"Lokale Schnittstelle:

*" TABLES

*" SHLP_TAB TYPE SHLP_DESCR_TAB_T

*" RECORD_TAB STRUCTURE SEAHLPRES

*" CHANGING

*" VALUE(SHLP) TYPE SHLP_DESCR_T

*" VALUE(CALLCONTROL) LIKE DDSHF4CTRL STRUCTURE DDSHF4CTRL

*"----------------------------------------------------------------------

*-- Lokale Tabelle zum Nachlesen der Daten

DATA: l_tcla_tab LIKE tcla OCCURS 0 WITH HEADER LINE.

DATA: BEGIN OF l_rec_struk,

mandt LIKE sy-mandt,

klart LIKE tcla-klart,

END OF l_rec_struk .

DATA: i_selopt TYPE ddshselopt OCCURS 0 WITH HEADER LINE.

DATA: i_interface TYPE ddshiface OCCURS 0 WITH HEADER LINE.



* EXIT immediately, if you do not want to handle this step IF callcontrol-step <> 'SELONE' AND

callcontrol-step <> 'SELECT' AND

" AND SO ON

callcontrol-step <> 'DISP'.

EXIT.

ENDIF.

*"----------------------------------------------------------------------

* STEP SELONE (Select one of the elementary searchhelps)

*"----------------------------------------------------------------------

* This step is only called for collective searchhelps. It may be used

* to reduce the amount of elementary searchhelps given in SHLP_TAB.

* The compound searchhelp is given in SHLP.

* If you do not change CALLCONTROL-STEP, the next step is the

* dialog, to select one of the elementary searchhelps.

* If you want to skip this dialog, you have to return the selected

* elementary searchhelp in SHLP and to change CALLCONTROL-STEP to

* either to 'PRESEL' or to 'SELECT'.

IF callcontrol-step = 'SELONE'.

i_selopt-shlpname = shlp-shlpname.

i_selopt-shlpfield = 'JAHR'.

i_selopt-sign = 'I'.

i_selopt-option = 'EQ'.

i_selopt-low = sy-datum(4).

APPEND i_selopt TO shlp-selopt.

CLEAR i_selopt.

READ TABLE shlp-interface INTO i_interface

WITH KEY shlpfield = 'Z_GR'.

IF sy-subrc = 0.

i_selopt-shlpname = shlp-shlpname.

i_selopt-shlpfield = 'Z_GR'.

i_selopt-sign = 'I'.

i_selopt-option = 'EQ'.

i_selopt-low = i_interface-value.

APPEND i_selopt TO shlp-selopt.

CLEAR i_selopt.

ENDIF.

callcontrol-step = 'PRESEL'.

EXIT.

ENDIF.

*"----------------------------------------------------------------------

* STEP PRESEL (Enter selection conditions)

*"----------------------------------------------------------------------

* This step allows you, to influence the selection conditions either

* before they are displayed or in order to skip the dialog completely.

* If you want to skip the dialog, you should change CALLCONTROL-STEP

* to 'SELECT'.

* Normaly only SHLP-SELOPT should be changed in this step.

IF callcontrol-step = 'PRESEL'.

* PERFORM PRESEL ..........

EXIT.

ENDIF.

*"----------------------------------------------------------------------

* STEP SELECT (Select values)

*"----------------------------------------------------------------------

* This step may be used to overtake the data selection completely.

* To skip the standard seletion, you should return 'DISP' as following

* step in CALLCONTROL-STEP.

* Normally RECORD_TAB should be filled after this step

IF callcontrol-step = 'SELECT'.

* PERFORM STEP_SELECT TABLES RECORD_TAB USING SHLP CHANGING RC.

* IF RC = 0.

* CALLCONTROL-STEP = 'DISP'.

* ELSE.

* CALLCONTROL-STEP = 'EXIT'.

* ENDIF.

EXIT. "Don't process STEP DISP additionally in this call.

ENDIF.

*"----------------------------------------------------------------------

* STEP DISP (Display values)

*"----------------------------------------------------------------------

* This step is called, before the selected data is displayed.

* You can e.g. modify or reduce the data in RECORD_TAB

* according to the users authority.

* If you want to get the standard display dialog afterwards, you

* should not change CALLCONTROL-STEP.

* If you want to overtake the dialog on you own, you must return

* the following values in CALLCONTROL-STEP:

* - "RETURN" if one line was selected. The selected line must be

* the only record left in RECORD_TAB. The corresponding fields of

* this line are entered into the screen.

* - "EXIT" if the values request should be aborted

* - "PRESEL" if you want to return to the selection dialog

IF callcontrol-step = 'DISP'.

* PERFORM AUTHORITY_CHECK TABLES RECORD_TAB USING SHLP.

*-- Hier werden die nicht anzeigbaren Einträge gelöscht

EXIT.

ENDIF.

ENDFUNCTION.

Re: Suchhilfe Exit ?

Beitrag von moin (ForumUser / 4 / 0 / 0 ) »
Suchhileexit ist drin, allerdings hat das Feld in shlp-interface bereits das Attribut "Nur Anzeigefeld":

FUNCTION z_bw_f4_uebung_exit.

*"----------------------------------------------------------------------

*"*"Lokale Schnittstelle:

*" TABLES

*" SHLP_TAB TYPE SHLP_DESCR_TAB_T

*" RECORD_TAB STRUCTURE SEAHLPRES

*" CHANGING

*" VALUE(SHLP) TYPE SHLP_DESCR_T

*" VALUE(CALLCONTROL) LIKE DDSHF4CTRL STRUCTURE DDSHF4CTRL

*"----------------------------------------------------------------------

*-- Lokale Tabelle zum Nachlesen der Daten

DATA: l_tcla_tab LIKE tcla OCCURS 0 WITH HEADER LINE.

DATA: BEGIN OF l_rec_struk,

mandt LIKE sy-mandt,

klart LIKE tcla-klart,

END OF l_rec_struk .

DATA: i_selopt TYPE ddshselopt OCCURS 0 WITH HEADER LINE.

DATA: i_interface TYPE ddshiface OCCURS 0 WITH HEADER LINE.



* EXIT immediately, if you do not want to handle this step IF callcontrol-step <> 'SELONE' AND

callcontrol-step <> 'SELECT' AND

" AND SO ON

callcontrol-step <> 'DISP'.

EXIT.

ENDIF.

*"----------------------------------------------------------------------

* STEP SELONE (Select one of the elementary searchhelps)

*"----------------------------------------------------------------------

* This step is only called for collective searchhelps. It may be used

* to reduce the amount of elementary searchhelps given in SHLP_TAB.

* The compound searchhelp is given in SHLP.

* If you do not change CALLCONTROL-STEP, the next step is the

* dialog, to select one of the elementary searchhelps.

* If you want to skip this dialog, you have to return the selected

* elementary searchhelp in SHLP and to change CALLCONTROL-STEP to

* either to 'PRESEL' or to 'SELECT'.

IF callcontrol-step = 'SELONE'.

i_selopt-shlpname = shlp-shlpname.

i_selopt-shlpfield = 'JAHR'.

i_selopt-sign = 'I'.

i_selopt-option = 'EQ'.

i_selopt-low = sy-datum(4).

APPEND i_selopt TO shlp-selopt.

CLEAR i_selopt.

READ TABLE shlp-interface INTO i_interface

WITH KEY shlpfield = 'Z_GR'.

IF sy-subrc = 0.

i_selopt-shlpname = shlp-shlpname.

i_selopt-shlpfield = 'Z_GR'.

i_selopt-sign = 'I'.

i_selopt-option = 'EQ'.

i_selopt-low = i_interface-value.

APPEND i_selopt TO shlp-selopt.

CLEAR i_selopt.

ENDIF.

callcontrol-step = 'PRESEL'.

EXIT.

ENDIF.

*"----------------------------------------------------------------------

* STEP PRESEL (Enter selection conditions)

*"----------------------------------------------------------------------

* This step allows you, to influence the selection conditions either

* before they are displayed or in order to skip the dialog completely.

* If you want to skip the dialog, you should change CALLCONTROL-STEP

* to 'SELECT'.

* Normaly only SHLP-SELOPT should be changed in this step.

IF callcontrol-step = 'PRESEL'.

* PERFORM PRESEL ..........

EXIT.

ENDIF.

*"----------------------------------------------------------------------

* STEP SELECT (Select values)

*"----------------------------------------------------------------------

* This step may be used to overtake the data selection completely.

* To skip the standard seletion, you should return 'DISP' as following

* step in CALLCONTROL-STEP.

* Normally RECORD_TAB should be filled after this step

IF callcontrol-step = 'SELECT'.

* PERFORM STEP_SELECT TABLES RECORD_TAB USING SHLP CHANGING RC.

* IF RC = 0.

* CALLCONTROL-STEP = 'DISP'.

* ELSE.

* CALLCONTROL-STEP = 'EXIT'.

* ENDIF.

EXIT. "Don't process STEP DISP additionally in this call.

ENDIF.

*"----------------------------------------------------------------------

* STEP DISP (Display values)

*"----------------------------------------------------------------------

* This step is called, before the selected data is displayed.

* You can e.g. modify or reduce the data in RECORD_TAB

* according to the users authority.

* If you want to get the standard display dialog afterwards, you

* should not change CALLCONTROL-STEP.

* If you want to overtake the dialog on you own, you must return

* the following values in CALLCONTROL-STEP:

* - "RETURN" if one line was selected. The selected line must be

* the only record left in RECORD_TAB. The corresponding fields of

* this line are entered into the screen.

* - "EXIT" if the values request should be aborted

* - "PRESEL" if you want to return to the selection dialog

IF callcontrol-step = 'DISP'.

* PERFORM AUTHORITY_CHECK TABLES RECORD_TAB USING SHLP.

*-- Hier werden die nicht anzeigbaren Einträge gelöscht

EXIT.

ENDIF.

ENDFUNCTION.

Seite 1 von 1

Vergleichbare Themen

3
Antw.
4854
Views
Suchhilfe: Zwei Dynpro-Felder aus 1 Suchhilfe beschicken
von meinrad » 03.03.2006 15:24 • Verfasst in Dialogprogrammierung
1
Antw.
1520
Views
Suchhilfe
von SAP_ENTWICKLER » 06.10.2014 08:29 • Verfasst in ABAP® Core
3
Antw.
7765
Views
ALV Suchhilfe
von sap_all » 20.09.2005 10:23 • Verfasst in ABAP® Core
4
Antw.
2411
Views
Suchhilfe
von Horst » 16.11.2005 12:54 • Verfasst in ABAP® für Anfänger
3
Antw.
2052
Views
Suchhilfe F4
von fbo » 04.12.2006 15:19 • Verfasst in ABAP® Core

Über diesen Beitrag


Unterstütze die Community und teile den Beitrag für mehr Leser und Austausch

Aktuelle Forenbeiträge

Dialog-Container mit Toolbar/Status
vor 14 Stunden von black_adept gelöst 23 / 3745
User Exit EXIT_RQCPRM10_001
vor 15 Stunden von a-dead-trousers 2 / 294
Trennen Strasse und Hausnummer
vor 21 Stunden von payten 13 / 10653
Daten an Tabelle binden
Gestern von Lukas Sanders 2 / 1346

Newsletter Anmeldung

Keine Beiträge verpassen! Wöchentlich versenden wir lesenwerte Beiträge aus unserer Community.
Die letzte Ausgabe findest du hier.
Details zum Versandverfahren und zu Ihren Widerrufsmöglichkeiten findest du in unserer Datenschutzerklärung.

Aktuelle Forenbeiträge

Dialog-Container mit Toolbar/Status
vor 14 Stunden von black_adept gelöst 23 / 3745
User Exit EXIT_RQCPRM10_001
vor 15 Stunden von a-dead-trousers 2 / 294
Trennen Strasse und Hausnummer
vor 21 Stunden von payten 13 / 10653
Daten an Tabelle binden
Gestern von Lukas Sanders 2 / 1346

Unbeantwortete Forenbeiträge

aRFC im OO-Kontext
vor 4 Wochen von ralf.wenzel 1 / 2879
Hilfe bei SWEC/SWE2
September 2024 von retsch 1 / 9472