Created
November 11, 2013 16:58
-
-
Save dantesco/7416471 to your computer and use it in GitHub Desktop.
Matchcode para campo de variante
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
PARAMETERS: p_var TYPE disvariant-variant. "ALV | |
INITIALIZATION. | |
* Search help | |
at selection-screen on value-request for p_var. | |
is_variant-variant = p_var. | |
is_variant-report = sy-repid. | |
call function 'REUSE_ALV_VARIANT_F4' | |
exporting | |
is_variant = is_variant | |
i_save = 'A' | |
i_display_via_grid = 'X' | |
importing | |
es_variant = is_variant | |
exceptions | |
not_found = 1 | |
program_error = 2 | |
others = 3. | |
if sy-subrc = 0. | |
p_var = is_variant-variant. | |
endif. | |
* Input check | |
at selection-screen on p_var. | |
is_variant-variant = p_var. | |
is_variant-report = sy-repid. | |
check is_variant-variant is not initial. | |
call function 'REUSE_ALV_VARIANT_EXISTENCE' | |
exporting | |
i_save = 'A' | |
changing | |
cs_variant = is_variant | |
exceptions | |
wrong_input = 1 | |
not_found = 2 | |
program_error = 3 | |
others = 4. | |
if sy-subrc ne 0. | |
message e204(0k) with is_variant-variant. | |
endif. |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment