Студопедия
Случайная страница | ТОМ-1 | ТОМ-2 | ТОМ-3
АрхитектураБиологияГеографияДругоеИностранные языки
ИнформатикаИсторияКультураЛитератураМатематика
МедицинаМеханикаОбразованиеОхрана трудаПедагогика
ПолитикаПравоПрограммированиеПсихологияРелигия
СоциологияСпортСтроительствоФизикаФилософия
ФинансыХимияЭкологияЭкономикаЭлектроника

CLEAR wa_sbook.

DATA result TYPE p DECIMALS 2. | ENDLOOP. ENDIF. | Wa_flight-seatsocc / wa_flight-seatsmax. | INSERT wa_flight INTO TABLE it_flight. | ID ’ACTVT’ FIELD ’02’. | WRITE: / ’Authority-Check Error’(001). ENDCASE. | Wa-percentage, ’%’. | Wa_sbook-loccurkey. | SELECT-OPTIONSname FORdata_object. | MESSAGE e045(bc400) WITH pa_car. ENDIF. |


Читайте также:
  1. BALTIC NUCLEAR POWER STATION
  2. Bilancio energetico dell'elettronucleare
  3. CLEAR AND PRESENT DANGER
  4. CLEAR wa_sbook.
  5. Combinations withclear, cut, fall, hold, let andhand
  6. Condition of construction of nuclear reactors in the world for 1998 on IAEA data ([16], tab. 11).

 


 

 

285 Exercise 16: Screens: Specifying the Next

Screen Dynamically

 

Exercise Duration: 40 Minutes

 

 

Exercise Objectives

 

After completing this exercise, you will be able to:

• Create pushbuttons on screens

• Evaluate the function codes triggered by the user by means of pushbuttons in order to control the program flow accordingly

• Set subsequent screens dynamically

 

 

Business Example

 

On the screen of your program ZBC400_##_DYNPRO_1 two pushbuttons with appropriate functions are to be implemented.

 

System Data

 

System: Will be assigned Client: Will be assigned User ID: Will be assigned Password: Will be assigned

Set up instructions: No special instructions when using a standard training system

 

Task 1:

 

Define the pushbuttons

 

1. Extend your program ZBC400_##_DYNPRO_1 or copy the template SAPBC400UDS_DYNPRO_2 to the new name ZBC400_##_DYNPRO_3 for further processing.

 

2. On the screen, define a pushbutton for returning to the basic list (Back) and one for saving the changed data in the database (Save).

 

Name of pushbutton Text Function code
PUSH_BACK Back BACK
PUSH_SAVE Save (or icon ICON_SYSTEM_SAVE) SAVE

 

 

Continued on next page


 

Task 2:

 

Implement dynamic control of subsequent screens

 

1. Name the 'OK' type field on the screen and define a data object of the same name (and corresponding type) in the program. We suggest the name OK_CODE.

 

2. Navigate in the flow logic. Create a PAI module by means of forward navigation. In it, implement the following function code handling:

 

Function code Action
BACK Back to basic list
SAVE Output information message 060 of message class BC400 and return to basic list
Any other action Process screen 100 again

 

3. Ensure that choosing Enter always displays screen 100, regardless of the navigation history. To do this, initialize the ok code field in a PBO module.


 

Solution 16: Screens: Specifying the Next

Screen Dynamically

 

Task 1:

 

Define the pushbuttons

 

1. Extend your program ZBC400_##_DYNPRO_1 or copy the template SAPBC400UDS_DYNPRO_2 to the new name ZBC400_##_DYNPRO_3 for further processing.

 

a) Carry out this step as usual.

 

2. On the screen, define a pushbutton for returning to the basic list (Back) and one for saving the changed data in the database (Save).

 

Name of pushbutton Text Function code
PUSH_BACK Back BACK
PUSH_SAVE Save (or icon ICON_SYSTEM_SAVE) SAVE

 

a) Carry out this step as described in the training material.

 

Task 2:

 

Implement dynamic control of subsequent screens

 

1. Name the 'OK' type field on the screen and define a data object of the same name (and corresponding type) in the program. We suggest the name OK_CODE.

 

a) Carry out this step as described in the training material. b) See source code excerpt in the model solution.

2. Navigate in the flow logic. Create a PAI module by means of forward navigation. In it, implement the following function code handling:

 

 

Continued on next page


 

Function code Action
BACK Back to basic list
SAVE Output information message 060 of message class BC400 and return to basic list
Any other action Process screen 100 again

 

a) See source code excerpt in the model solution.

 

3. Ensure that choosing Enter always displays screen 100, regardless of the navigation history. To do this, initialize the ok code field in a PBO module.

 

a) See the source code excerpt in the model solution.

 

Result

 

Source code excerpt: SAPBC400UDS_DYNPRO_3

 

 

REPORT sapbc400uds_dynpro_3.

 

 

CONSTANTS: actvt_display TYPE activ_auth VALUE ’03’, actvt_change TYPE activ_auth VALUE ’02’.

 

PARAMETERS pa_anum TYPE sbook-agencynum.

 

 

* workarea for SELECT

DATA wa_sbook TYPE sbook.

 

 

* workarea for data communication with screen

TABLES sdyn_book.

 

 

* variable for function code of user action


Дата добавления: 2015-11-16; просмотров: 83 | Нарушение авторских прав


<== предыдущая страница | следующая страница ==>
CALL SCREEN 100.| MODULE user_command_100.

mybiblioteka.su - 2015-2024 год. (0.007 сек.)