PackagePackagetypeA library you install and call yourself.See every one →What this type is →independently maintainedindependently maintainedoriginPublished by one person or a small company outside SAP. Says nothing about quality; the readings say that.See every one →

abap-ui-tools

A helper class for the classic ABAP dynpro UI: hiding, disabling and requiring screen fields, setting dropdown values, and asking yes/no questions, in single calls.

Manipulating dynpro screen fields normally means writing a loop at screen and checking group and field names by hand in the PBO event. ZCL_UITOOLS, used through inheritance or as an instance, replaces that with direct calls such as field('MATNR')->hide() or group('GR1')->set_required() to hide, disable or require whole groups or single fields, and the same field() method sets a list box's dropdown values. Its ask() and ask_with_cancel() methods wrap POPUP_TO_CONFIRM for yes/no and yes/no/cancel questions, with an optional long text pulled from an SE61 document. A demo report, ZP_UITOOLS_DEMO, shows the calls in use.

Facts

Last pushLicenceMIT

Where it sits

Lives in
Provides
SAP GUI screens and listsABAPSAP GUI screens and listscapabilityBuilding screens, lists and interactive controls for the SAP GUI. Producing a web interface is [UI written in ABAP](capability:abap-ui-from-abap); operating an existing screen programmatically is [GUI automation](capability:gui-automation).
Requires
throwthrowartifactThe coding depends on ZCL_THROW to raise its exceptions, as the README states.

Who is behind it

Jörg KrauseJörg KrausePersonMaintains this
In the atlas: maintains 5, contributes to 6
@jrgkraus
maintainer

What it declares

Every artifact

Type
Package
Origin
Independently maintained

As a package

Where it runs
does not say
Distributed through
does not say

Connections2

README

quoted from jrgkraus/abap-ui-tools under MIT, read
jrgkraus/abap-ui-tools/README.mdOn GitHub

Collection of tools for the classic dynpro UI of SAP

The provided class ZCL_UITOOLS can be used via inheritance or as an instance.

Manipulate screen fields in PBO

Instead of using loop at screen., you can now use the following calls to influence on the screen behaviour. The following examples are based on a class that inheritates from ZCL_UITOOLS

" hide a field by group or name
group( 'GR1' )->hide( ).
field( 'MATNR' )->hide( ).
" hide a selection or a parameter of a report screen
selection( 'S_MATNR' )->hide( ).
" set fields to no-input
group( 'GR1' )->set_noinput( ).
field( 'MATNR' )->set_noinput( ).
" make a field obligatory
group( 'GR1' )->set_required( ).
field( 'MATNR' )->set_required( ).

Set dropdown values in PBO

Using the field( ) method, you can set dropdown values for a list box

  field( 'GROUPNR' )->set_dropdown_values(
    value #(
      ( key = '1' text = 'First group' )
      ( key = '2' text = 'Second group' )
      ( key = '3' text = 'Third group' )
      ( key = '4' text = 'Forth group' ) ) ).

Simple Yes/No (/Cancel) queries

The methods ask( ) and ask_with_cancel( ) provide a simple interface to POPUP_TO_CONFIRM

if ask( question = 'Is this OK?' ).
  message 'OK' type 'I'.
else.
  message 'not OK' type 'I'.
endif.
" verson that displays also a cancel button
try.
    if ask_with_cancel( question = 'Is this OK?' ).
      message 'OK' type 'I'.
    else.
      message 'not OK' type 'I'.
    endif.
  catch zcx_uitools_user_cancelled into data(e).
    message e type 'I' display like 'E'.
endtry.

Both methods provide also an optional parameter LONGTEXT where you can pass a longtext object created with SE61

Demo report

Explore ZP_UITOOLS_DEMO to learn more

dependencies

The coding uses ZCL_THROW, which depends on ZCL_ASSERTABLE_UNIT

MIT, read
SAP GUI screens and lists
  1. abeljohny/ZAPMacro DSL turning a one-line select into an ALV listfrom ABAP
  2. abap-ui-toolboxABAP classes for classic SAP GUI development: ALV, screens, treesfrom ABAP
  3. alv_utilitiesABAP class wrapping SALV to set column properties in one callfrom ABAP
  4. abap-alv-struc-viewerALV table view generated from a DDIC structurefrom ABAP
  5. abapEasyALVWrapper classes over classic ALV and SALV reportingfrom ABAP
  6. cds2alvGenerator for ALV list reports from a CDS view's field definitionsfrom ABAP
  7. guidrasilVisual designer generating ABAP code for classic SAP GUI screensfrom ABAP
  8. abapMermaidRenders Mermaid diagrams inside an SAP GUI containerfrom ABAP
  9. ZwdDynscreenSelection screens and popups generated from ABAP objects, no dynprofrom ABAP

Details

Sources3
dotabapdiscovered herechecked
github.com/jrgkraus/abap-ui-toolstree, pushes, contributors, CIchecked
README.mdquoted, and what the entry declareschecked

Sources are graph entities: the same page may back several entries, and an unreachable source flags every row that rests on it.

Compatibility and provenance
releases and cadence0
discovered viadotabap
first seen in the atlas
ecosystem and domainabap, ui-and-frontend-bridge
abaplint
issues under its own abaplint configuration187
lines567
statements325
objects6
files10
analysed, main
abaplint version2.120.84
History in the atlas1
  1. First seen.
For your agent
Ref
artifact:jrgkraus-abap-ui-tools
JSON
/artifacts/jrgkraus-abap-ui-tools.json
MCP
Connecting an agent