CALL FUNCTION 'CR_CAPACITY_AVAILABLE'
EXPORTING
datub = l_date_from
datuv = l_date_from
kapid = l_kapid
* pdays_only = 'X'
* DURATION =
IMPORTING
pdays = l_pdays
EXCEPTIONS
not_found = 1
missing_parameter = 2
no_capacity = 3
date_outside_factorycalendar = 4
invalid_parameter = 5
OTHERS = 6.
EXPORTING
datub = l_date_from
datuv = l_date_from
kapid = l_kapid
* pdays_only = 'X'
* DURATION =
IMPORTING
pdays = l_pdays
EXCEPTIONS
not_found = 1
missing_parameter = 2
no_capacity = 3
date_outside_factorycalendar = 4
invalid_parameter = 5
OTHERS = 6.