Regarding Module Pool Text Field
Hi,
Can any body tell , is there any possiblity to change the font style and size of the Module pool text field.( Because I want a Heading in the screen)
Regards
Prashanth
Hi,
Goto the Layout Editor of your Screen.
Double click on the text field .. Double clk the text fild, and from the Botton right u can see an arrow icon -> click on that > will open a Popup > in that <b> set Area Title to TRUE </b>.
Rgds,
Jothi.
Do Award pts for helpful answers.
Similar Messages
-
Module Pool Text field should be display Bold
Hi Freinds,
I have created Module Pool.
1. My requirement is Text Field display Bold & I want to Change of Text Size.
2. After executing Menu bar option are Disable mode, I want in Enable mode.
Thx in Advance.1) By default in PBO you can see 'MODULE status_0001 OUTPUT'
2) if you double click on that it will take you to enable the PF-STATUS (please check the below code).
3) If you double click on PF_0001 then menu painter will be opened to create status.
4) For more information[ click here.|http://help.sap.com/saphelp_nw04s/helpdata/en/d1/801ce8454211d189710000e8322d00/frameset.htm]
*& Module STATUS_0001 OUTPUT
* text
MODULE status_0001 OUTPUT.
SET PF-STATUS 'PF_0001'.
SET TITLEBAR 'TB_0001'.
ENDMODULE. " STATUS_0001 OUTPUT
regards,
~Satya -
No Interval effect in Module Pool Program field
Dear All,
If I want to introduce No Interval effect of the Report Selection screen ,in Module Pool program field,what will be the approach.
Thx in Adv.Define the selection-screen as a subscreen and call it in the initial screen of ur transaction.
Check this link
http://help.sap.com/saphelp_47x200/helpdata/en/e7/deb237b9a9a968e10000009b38f8cf/content.htm
Also check this demo program
<b>demo_sel_screen_as_subscreen.</b> -
Module Pool Text Editor Problem
Hi
I have developed module pool program which has 3 tab strips. In the last (3rd) Tab Strip I need to input Long Text. I have the done the coding but when I go to the Last tab and then come back to any other tabs, the text editor is overwriting the other fields in the other tabs. Can any tell how to solve this problem
This is he code I have written
****90000******Screen
PROCESS BEFORE OUTPUT.
MODULE status_9000.
MODULE modify_screen9000.
module test_me.
LOOP AT t_operation INTO s_operation WITH CONTROL toperation.
MODULE move_data.
MODULE modiy_screentblctrl.
ENDLOOP.
CALL SUBSCREEN sub1 INCLUDING sy-repid '9001'.
CALL SUBSCREEN sub2 INCLUDING sy-repid '9002'.
CALL SUBSCREEN sub3 INCLUDING sy-repid '9003'.
PROCESS AFTER INPUT.
MODULE cancel AT EXIT-COMMAND.
CHAIN.
FIELD zaodheader-heatnum MODULE check_heatnumber.
ENDCHAIN.
LOOP AT t_operation.
MODULE update_itab.
ENDLOOP.
MODULE user_command_9000.
CALL SUBSCREEN sub1.
CALL SUBSCREEN sub2.
CALL SUBSCREEN sub3.
**************9003*****
PROCESS BEFORE OUTPUT.
MODULE STATUS_9003.
MODULE display_texteditor.
PROCESS AFTER INPUT.
MODULE USER_COMMAND_9003.
**************9003*****
DATA : ccont TYPE REF TO cl_gui_custom_container,
tedit TYPE REF TO cl_gui_textedit.
MODULE display_texteditor OUTPUT.
CREATE OBJECT ccont
EXPORTING
parent =
container_name = 'CC'
style =
lifetime = lifetime_default
repid =
dynnr =
no_autodef_progid_dynnr =
EXCEPTIONS
cntl_error = 1
cntl_system_error = 2
create_error = 3
lifetime_error = 4
lifetime_dynpro_dynpro_link = 5
OTHERS = 6 .
IF sy-subrc <> 0.
ENDIF.
CREATE OBJECT tedit
EXPORTING
max_number_chars =
style = 0
wordwrap_mode = wordwrap_at_windowborder
wordwrap_position = -1
wordwrap_to_linebreak_mode = false
filedrop_mode = dropfile_event_off
parent = ccont
lifetime =
name =
EXCEPTIONS
error_cntl_create = 1
error_cntl_init = 2
error_cntl_link = 3
error_dp_create = 4
gui_type_not_supported = 5
OTHERS = 6.
IF sy-subrc <> 0.
MESSAGE ID SY-MSGID TYPE SY-MSGTY NUMBER SY-MSGNO
WITH SY-MSGV1 SY-MSGV2 SY-MSGV3 SY-MSGV4.
ENDIF.
ENDMODULE. " DISPLAY_TEXTEDITOR OUTPUT
Edited by: kumar1819 on Apr 7, 2010 8:05 AM
SolvedHi kumar,
**************9003*****
PROCESS AFTER INPUT.
MODULE USER_COMMAND_9003.
Case SY-UCOMM.
When 'TAB2'.
Call screen 9002.
**************9003*****
In 9001 and 9002 screen what code u r writing.
Regards,
Raj. -
Module-pool screen field value under POV event
Hi All,
I have one issue...please suggest me solution for this.
In module-pool program i have one screen(1000) which has one field(hrname_1000).
Under this event:
PROCESS ON VALUE-REQUEST.
FIELD hrname_1000 MODULE hrname_1000.
under this module hename_1000 i have used F4IF_INT_TABLE_VALUE_REQUEST to put a search help for field hrname_1000.
after that i am trying to retrive HR related stuff's based on the field on module-pool i.e i am using hrname_1000 in the where condition.
but problem is that im not getting value for hrname_1000 which im giving in the module-pool screen.
thats y my select query is not working.
Where as im getting values for the hrname_1000 under PBO & PAI.
It will look like below.
PROCESS ON VALUE-REQUEST.
FIELD hrname_1000 MODULE hrname_1000.
(under the above module)
SELECT DISTINCT ename plans FROM pa0001 INTO CORRESPONDING FIELDS OF TABLE itab WHERE stell = '50001026'.
LOOP AT itab INTO wa WHERE ename = hrname_1000.
ENDLOOP.
Please suggest
Thanks & regards
AnsumeshIn some of the cases the screen field is present in the screen but not holding the value in the required structure or field.
so here u need to check the option of reading the screen field values explictly..
//once u hit an enter and do the f4 i think the value will be there ...but if u dont hit enter and do an F4 the value cannot hold and i think u r in this case ..
1.Fill the screen field name in the structure dynpread.
DATA: BEGIN OF DYNP_VALUES OCCURS 10.
INCLUDE STRUCTURE DYNPREAD.
DATA: END OF DYNP_VALUES.
DYNP_VALUES-FIELDNAME = 'HRNAME_1000'.
APPEND DYNP_VALUES.
* read screen values
CALL FUNCTION 'DYNP_VALUES_READ'
EXPORTING
DYNAME = HELP_REPID "call the repid of ur prog
DYNUMB = HELP_DYNNR "pass the screen number
TABLES
DYNPFIELDS = DYNP_VALUES
EXCEPTIONS
OTHERS = 1.
now dynp_values hold the field name and field value of the screen .
now
SORT DYNP_VALUES BY FIELDNAME.
READ TABLE DYNP_VALUES WITH KEY 'HRNAME_1000' BINARY SEARCH.
IF SY-SUBRC EQ 0.
HELP_XXXX = DYNP_VALUES-FIELDVALUE. "store the value into a variable
TRANSLATE HELP_XXXX TO UPPER CASE.
ENDIF.
Now check the code with the value if its getting populated which once there will make ur select work ..
Vijay.. -
Module pool screen field should default without pressing enter
Hi
I have got a main module pool screen which has a tabstrip with four tabs.
There are 2 fields in the main screen when we select from F4 for the first field then the field 2 should default in case of a condition.
This happens only when i press enter. I want the second field to change as soon as the first field is selected.
How do I trigger the PAI as soon as the field 1 is selected.
eg: Field 1 : i/p
Field 2 : display
Field 3 : i/p
On F4 for field 1 say i select value 'A' then the valu for field 3 should default to value 'B'. Also field 2 should be displayed based on combination of field 1 and field 2. But now it does it only on pressing enter.
How do I solve this problem?Also if i select field 1 value A and dont press enter and go to the subscreen tab then it does not do any thing. It allows to go on the subscreen tab. But actually it should default the field 3 value. It does it only when I press enter.
Also the F4 is from dictionary that is the screen fields are from dictionary. I have not created any F4 for the fields.
Please help me solve this problem
Regards,
mozilaHi
You can achieve this using List Box only not by Input Field. Since Input field doesn't trigger automatic PAI/PBO
Go through the below thread
populate drop down menu based on entry in another field
or an alternative is--> In PBO use POPUP_GET_VALUES Fm to get the First input field based on that you can enter further values
unicode error
Cheerz
Ram -
Regarding Module Pool Screen Painter
Dear All,
Hi all. When i am using 4.7 i am able to see all the icons like check box .radio buttons,push buttons ,table control and all . There i can drag and drop on the screen easily . I can see this all icons on the left side in the screen painter. In ecc i tried to create a module pool program. In that screen painter i am not able to see these icons in that screen .
When i am clicking on layout on initial screen it is showing ''''EU_SCRP_WN32 : timeout during allocate / CPIC-CALL: 'ThSAPCMRCV' '''' . That is also in text format with some lines and all. I was totally struck here . Please help me in this .
Regards,
Madhu.How can you solve the problem ? Please explain it.
-
Regarding module pool with alv
hi experts,
i have developed a module pool program in which the data is coming in the table control ,what the user wants that on clicking one push button a alv report will come depending upon the data which i enterd in the selection screen of the module pool,,for this what sud i write under the push button plz help me....Hi
In the table control keep a Button
First select the Records in the tables control into an Internal table
when you press that REPORT button in the table control screen these Selected records data which is in Internal table has to be displayed in a ALV report.
Hope when the data is internal tables just call the fun module of ALV
In the PAI of table control screen
case ok_code.
when 'REPT'.
loop at itab where v_chk = 'X'.
...append the selected records to another ITAB1.
endloop.
leave to list-processing
perform_display_report.
endcase.
In the perform you process the internal table, build the field catalog and display the ALV report
Reward points for useful Answers
Regards
Anji -
Module Pool:editable field not changing
Hi All,
I created one module pool program with three fields MATNR,EBELN,KTMNG(qty). KTMNG is user key in accordingly to create delivery order.
Now the problem is when user key in KTMNG field value let say 10.000.when press enter Again its taking the database value(20.000 for example).
how to keep the user key value 10.000.
here is my coding:
PROCESS BEFORE OUTPUT.
LOOP AT ITAB INTO WA WITH CONTROL tabcontrol.
MODULE STATUS_0100.
ENDLOOP.
PROCESS AFTER INPUT.
MODULE USER_COMMAND_0100.
LOOP AT ITAB.
ENDLOOP.
MODULE USER_COMMAND_0100 INPUT.
CASE SY-UCOMM.
WHEN 'DIS'.
REFRESH:ITAB.
SELECT EBELN MATNR KTMNG INTO CORRESPONDING FIELDS OF TABLE ITAB FROM EKPO
WHERE EBELN EQ EKPO-EBELN.
WHEN 'EXIT'.
LEAVE PROGRAM.
ENDCASE.
ENDMODULE. " USER_COMMAND_0100 INPUT
MODULE STATUS_0100 OUTPUT.
SET PF-STATUS 'ZTESTING'.
SET TITLEBAR 'ZTEST'.
MOVE:WA-EBELN TO EKKO-EBELN,
WA-KTMNG TO EKPO-KTMNG,
WA-MATNR TO EKPO-MATNR.
VCONTROL-LINES = SY-DBCNT.
ENDMODULE.
Please help me.
Thank You,
Anu.PROCESS BEFORE OUTPUT.
LOOP AT ITAB INTO WA WITH CONTROL tabcontrol.
MODULE STATUS_0100.
ENDLOOP.
PROCESS AFTER INPUT.
MODULE USER_COMMAND_0100.
LOOP AT ITAB.
" add this
CHAIN.
FIELD EKKO-EBELN.
FIELD EKPO-KTMNG.
FIELD EKPO-MATNR.
Modify tablecontrol.
ENDCHAIN.
ENDLOOP.
MODULE USER_COMMAND_0100 INPUT.
CASE SY-UCOMM.
WHEN 'DIS'.
" Comment this start and Pushi to PBO and check if ITAB is initial then do below Qyery
REFRESH:ITAB.
SELECT EBELN MATNR KTMNG INTO CORRESPONDING FIELDS OF TABLE ITAB FROM EKPO
WHERE EBELN EQ EKPO-EBELN.
" Comment this end
WHEN 'EXIT'.
LEAVE PROGRAM.
ENDCASE.
ENDMODULE. " USER_COMMAND_0100 INPUT
MODULE STATUS_0100 OUTPUT.
SET PF-STATUS 'ZTESTING'.
SET TITLEBAR 'ZTEST'.
MOVE:WA-EBELN TO EKKO-EBELN,
WA-KTMNG TO EKPO-KTMNG,
WA-MATNR TO EKPO-MATNR.
VCONTROL-LINES = SY-DBCNT.
ENDMODULE.
MODULE TABLECONTROL OUTPUT. "New addition in PAI for Modify
MOVE:EKKO-EBELN TO WA-EBELN,
EKPO-KTMNG TO WA-KTMNG ,
EKPO-MATNR TO WA-MATNR .
MODIFY ITAB FROM wa INDEX tabcontrol-current_line
ENDMODULE -
Custom module pool + Amount field decimals display same as standard screen display
Hi All,
Requirement: A custom module program screen field has to be designed which displays decimal values of amount fields same as amount fields in standard screen.
Standard screen behavior: If the standard screen fields are observed, they refer to data elements WRBTR or AZSOL_F05A (transactions FB50/FB03/FB01). However, number of decimal places that are visible on screen are dependent on the currency that is provided.
Both the data elements have 2 decimal places.
For currency USD two decimal places are displayed - in TCURX - decimal places are two.
For currency JPY or CLP - zero decimal places are displayed - in TCURX - decimal places are zero.
i.e., even though the screen field refers to data element or domain that has the characteristic to show 2 decimal places, based on currency, decimal places are adjusted.
I would like to know how this is happening on standard screen fields.
Solution Required for: How to make the custom screen amounts to display same number of decimal places as standard screen amount fields.
P.S: Before posting the query here, research has been done in SDN and other places. It has been identified that quantity fields adjustments are discussed. However for amount field even though discussed earlier, did not reach a conclusion.
I would like to get a solution for this one.
Thanks in advance.
Goutham.Thank you all for taking time to take a look at this query.
This issue has been resolved.
Resolution: If the standard transactions (FI transactions in specific) are observed, whenever there is a field that displays amount value, there will be a corresponding field (may not be beside the amount field, somewhere on the screen or in the same sequence of screens) where the currency key value would be entered.
For instance, if you look at FB50 - there is field on top for the user to input currency key value (like USD or CLP or INR).
When any amount field is declared - this currency key field is provided as the reference field in the screen attributes of the amount field.
In short, in the custom module pool program, provide a field that holds currency key value and use this field as reference field for the amount fields.
Do repond to this thread if the resolution is not clear.
Thank you all once again.
Goutham. -
Doubt regarding module pool program
Hi experts,
I need to use bapi in module pool program
can we use it ? I hope we can use,
Please any body give some sample code
Thanks in advance
Rangabapi like another function module can be used in module pool based ojn ur desire
a sample code is :
case sy-ucomm.
when 'create'
call bapi u require
end case
hope it gives u an idea
regards
navjot
reward accordingly -
hi all,
i have got 3 radio buttons
when i click first button it should ask me that, enter the value in text field i.e it should be mandatory.....
this is my code.......
IF ADD = 'X'.
RES = VAR1 + VAR2.
ELSEIF SUB = 'X'.
if var1 > var2.
RES = VAR1 - VAR2.
else.
message E001(zabc) with 'error'.
endif.
ELSEIF MUL = 'X'.
RES = VAR1 * VAR2.
ENDIF.
for ur information i manage the beloe code........
loop at screen.
if ADD = 'X'.
IF SCREEN-NAME = 'VAR1 '.
screen-REQUIRED = '1'.
ENDIF.
endif.
ENDLOOP.
but exactly where to write this code........
regards,
PawanHi,
in AT SELECTION_SCREEN event write your code:
if add = 'X'.
if var1 is initial and var2 is initial.
message .....
endif.
endif.
Regards,
Subramanian -
Regarding Module Pool's Cancel button
Hi Guys,
Please help me I have created on Module Pool and now this module pool is called through a a UserExit .
now the thing is if i cancel button which is placed on my popup screen then it is still going into the output which is wrong it should show up the previous screen.
My code for the Sy-ucomm = cancel is
IF SY-UCOMM = 'CANC'.
SET SCREEN 0.
LEAVE SCREEN.
ENDIF.
Can you please provide me some code by which i can go to the previous screen.I am calling the Module pool through User exit and inside user exit i am calling FM which calls my screen.
Userexit -> FM -> ModulePool
here is the code :
***INCLUDE LZRMA_NOTIFO01 .
*& Module STATUS_0150 OUTPUT
* text
MODULE STATUS_0150 OUTPUT.
* SET PF-STATUS SY-DYNNR.
* SET TITLEBAR SY-DYNNR.
ENDMODULE. " STATUS_0150 OUTPUT
*& Module CUA_STATUS OUTPUT
* text
MODULE CUA_STATUS OUTPUT.
* SET PF-STATUS SY-DYNNR.
* SET TITLEBAR SY-DYNNR.
ENDMODULE. " CUA_STATUS OUTPUT
*& Module EXIT_SCREEN INPUT
* text
MODULE EXIT_SCREEN INPUT.
DATA: C_FCODE_ABBR LIKE SY-PFKEY VALUE 'ABBR' .
break-point.
CASE OK-CODE.
WHEN C_FCODE_ABBR.
*-- Abbrechen
* Daten zurücknehmen
CLEAR RQM01.
* RAISE CANCEL.
set screen 0.
LEAVE TO SCREEN 0.
call transaction 'QM01'.
ENDCASE.
IF SY-UCOMM = 'CANC'. " Here is the SY-UCOMM Where i have to handle the CANC BUTTON
* SET SCREEN 0.
* LEAVE SCREEN.
LEAVE PROGRAM.
ENDIF.
ENDMODULE. " EXIT_SCREEN INPUT
*& Module CHECK_NOTIF_NO INPUT
* text
MODULE CHECK_NOTIF_NO INPUT.
*& Below condition checks if the user enter a Notification Num and Porduction
* Order Then Message comees Please enter a Prod Order or RMA Notif Num only
* Process cannot accept both.
IF NOT VIQMEL-QMNUM IS INITIAL.
IF NOT RQM01-FERTAUFNR IS INITIAL.
MESSAGE E904(QM). " Please enter a Prod order or RMA Notif Num only.
" Process can't accept both
ENDIF.
ENDIF.
*& If Production order is entered, then check if the Order type is 'AES1' or *
*& 'AES3'AES2,AES4, AES5, AES6,ICSO, PM01, PM02, RMA, SM01, SM02, ZEXR,
*& Message flashes ' Please enter only enter RMA Notif Number. *
data: v_dauat like afpo-dauat.
SELECT SINGLE DAUAT INTO V_DAUAT FROM AFPO WHERE AUFNR = RQM01-FERTAUFNR.
if sy-subrc = 0.
IF V_DAUAT = 'AES1' OR V_DAUAT = 'AES3' OR
V_DAUAT = 'AES2' OR V_DAUAT = 'AES4' OR
V_DAUAT = 'ICSO' OR V_DAUAT = 'PM01' OR
V_DAUAT = 'PM01' OR V_DAUAT = 'RMA' OR
V_DAUAT = 'SM01' OR V_DAUAT = 'SM02' OR V_DAUAT = 'ZEXR'..
MESSAGE E905(QM). " Please Only enter a RMA Notif Number.
ENDIF.
endif.
ENDMODULE. " CHECK_NOTIF_NO INPUT
*& Module FEAUF_SAAUF_CHECK INPUT
* text
MODULE FEAUF_SAAUF_CHECK INPUT.
OK-CODE = SY-UCOMM.
*Added by CChauhan
IF VIQMEL-QMNUM IS INITIAL.
*& End of Addition by CChauhan
IF NOT RQM01-FERTAUFNR IS INITIAL
AND ( NOT RQM01-VERID IS INITIAL
OR NOT RQM01-RM_WERKS IS INITIAL
OR NOT RQM01-RM_MATNR IS INITIAL ).
* only production order or manufacturing version meaningfully
MESSAGE E902(QM).
ENDIF.
*Added by CChauhan
ENDIF.
*& End of Addition by CChauhan
ENDMODULE. " FEAUF_SAAUF_CHECK INPUT
*& Module FEAUF_FEPOS_CHECK INPUT
* text
MODULE FEAUF_FEPOS_CHECK INPUT.
IF VIQMEL-QMNUM = ''.
IF RQM01-FERTAUFNR = ''
AND RQM01-FERTVORNR <> ''.
MESSAGE E903(QM).
ENDIF.
ENDIF.
IF SY-UCOMM = 'CANC'.
LEAVE SCREEN.
ENDIF.
ENDMODULE. " FEAUF_FEPOS_CHECK INPUT
*& Module FAUF_LESEN INPUT
* text
MODULE FAUF_LESEN INPUT.
*& Added by CChauhan Date: 01/23/2007
*& Execute further if RMa_Notif(VIQMEL-QMNUM)ield is blank.
IF VIQMEL-QMNUM IS INITIAL.
*&End by CChauhan Date: 01/23/2007
PERFORM FAUF_LESEN USING RQM01-FERTAUFNR
RQM01-FERTVORNR
CHANGING CAUFV
AFVC.
* Belegdaten an Qualitätsmeldung übergeben
PERFORM FAUF_TO_QMEL USING CAUFV
AFVC
CHANGING RQM01.
*& Added by CChauhan Date: 01/23/2007
ENDIF.
*&End by CChauhan Date: 01/23/2007
ENDMODULE. " FAUF_LESEN INPUT
*& Form FAUF_LESEN
* text
* -->P_RQM01_FERTAUFNR text
* -->P_RQM01_FERTVORNR text
* <--P_CAUFV text
* <--P_AFVC text
FORM FAUF_LESEN USING VALUE(P_AUFNR) LIKE RQM01-FERTAUFNR
VALUE(P_VORNR) LIKE RQM01-FERTVORNR
CHANGING VALUE(P_CAUFV) LIKE CAUFV
VALUE(P_AFVC) LIKE AFVC .
CALL FUNCTION 'QMHL_HELP_FAUF'
EXPORTING
I_AUFNR = P_AUFNR
I_VORNR = P_VORNR
I_FOLGE = G_FOLGE
IMPORTING
E_CAUFV = P_CAUFV
E_AFVC = P_AFVC
EXCEPTIONS
ORDER_NOT_FOUND = 1
OPERATION_NOT_FOUND = 2
OTHERS = 3.
IF SY-SUBRC <> 0.
MESSAGE ID SY-MSGID TYPE SY-MSGTY NUMBER SY-MSGNO
WITH SY-MSGV1 SY-MSGV2 SY-MSGV3 SY-MSGV4.
ENDIF.
ENDFORM. " FAUF_LESEN
*& Form FAUF_TO_QMEL
* text
* -->P_CAUFV text
* -->P_AFVC text
* <--P_RQM01 text
FORM FAUF_TO_QMEL USING VALUE(P_CAUFV) LIKE CAUFV
VALUE(P_AFVC) LIKE AFVC
CHANGING P_RQM01 LIKE RQM01.
* zunächst Berechtigung für Meldungsart/Werk prüfen
PERFORM CHECK_QAUT_QMEL USING SY-TCODE
TQ80-QMART
P_CAUFV-WERKS.
* Materialnummer des Fertigprodukts ermitteln
SELECT * FROM AFPO
WHERE AUFNR = P_CAUFV-AUFNR.
* Materialnummer steht in der ersten Auftragsposition
EXIT.
ENDSELECT.
IF SY-SUBRC IS INITIAL.
* Materialnummer übernehmen
P_RQM01-MATNR = AFPO-MATNR.
IF NOT AFPO-MATNR IS INITIAL.
PERFORM MATERIAL_CHECK USING AFPO-MATNR.
ENDIF.
* Charge
P_RQM01-CHARG = AFPO-CHARG.
*--- Lieferantencharge bestimmen
IF NOT P_RQM01-CHARG IS INITIAL.
SELECT SINGLE * INTO MCHA FROM MCHA
WHERE MATNR = P_RQM01-MATNR
AND WERKS = P_RQM01-MAWERK
AND CHARG = P_RQM01-CHARG.
IF SY-SUBRC EQ 0.
MOVE MCHA-LICHA TO P_RQM01-LICHN.
ENDIF.
ENDIF.
P_RQM01-LGORTCHAR = AFPO-LGORT.
ENDIF.
P_RQM01-MAWERK = P_CAUFV-WERKS.
IF NOT AFPO-MATNR IS INITIAL
AND NOT P_CAUFV-WERKS IS INITIAL.
PERFORM MATERIAL_WERK_CHECK USING AFPO-MATNR
P_CAUFV-WERKS.
ENDIF.
* Revisionsstand
P_RQM01-REVLV = P_CAUFV-REVLV.
* reklamierte Menge
P_RQM01-RKMNG = P_CAUFV-GAMNG - P_CAUFV-GASMG.
P_RQM01-BZMNG = P_CAUFV-GAMNG - P_CAUFV-GASMG.
P_RQM01-MGEIN = P_CAUFV-GMEIN.
* Arbeitsplatz
P_RQM01-ARBPL = P_AFVC-ARBID.
* eindeutiger Schluessel fuer Vorgang
P_RQM01-FERTAUFPL = P_AFVC-AUFPL.
P_RQM01-PNLKN = P_AFVC-APLZL.
* Info über automatische Datenübernahme
MESSAGE S026(QM) WITH P_CAUFV-AUFNR RQM01-FERTVORNR.
ENDFORM. " FAUF_TO_QMEL
*& Form CHECK_QAUT_QMEL
* text
* -->P_SY_TCODE text
* -->P_TQ80_QMART text
* -->P_P_CAUFV_WERKS text
FORM CHECK_QAUT_QMEL USING VALUE(P_TCODE)
VALUE(P_QMART)
VALUE(P_WERK).
CHECK NOT P_WERK IS INITIAL.
MOVE-CORRESPONDING RQM01 TO H_VIQMEL.
CALL FUNCTION 'QAUT_QMEL'
EXPORTING
I_WERKS = P_WERK
I_QMART = P_QMART
I_TCODE = P_TCODE
I_VIQMEL = H_VIQMEL.
ENDFORM. " CHECK_QAUT_QMEL
*& Form MATERIAL_CHECK
* text
* -->P_AFPO_MATNR text
FORM MATERIAL_CHECK USING VALUE(P_MATNR).
*-- lokale Daten
DATA : BEGIN OF L_DUMMY_TAB OCCURS 0,
DUMMY(1),
END OF L_DUMMY_TAB.
* Prüfung nur, falls Materialnummer und Werk gefüllt
CHECK NOT P_MATNR IS INITIAL.
* Verprobung auf MARA-Segment
MOVE C_MARA_SEGMENT TO MTCOM-KENNG.
MOVE P_MATNR TO MTCOM-MATNR.
TABLES: MTCOR.
CALL FUNCTION 'MATERIAL_READ'
EXPORTING
SCHLUESSEL = MTCOM
IMPORTING
MATDATEN = MARA
RETURN = MTCOR
TABLES
SEQMAT01 = L_DUMMY_TAB
EXCEPTIONS
ACCOUNT_NOT_FOUND = 01
BATCH_NOT_FOUND = 02
FORECAST_NOT_FOUND = 03
LOCK_ON_ACCOUNT = 04
LOCK_ON_MATERIAL = 05
LOCK_ON_PLANT = 06
LOCK_ON_SALES = 07
LOCK_ON_SLOC = 08
LOCK_SYSTEM_ERROR = 09
MATERIAL_NOT_FOUND = 10
PLANT_NOT_FOUND = 11
SALES_NOT_FOUND = 12
SLOC_NOT_FOUND = 13
SLOCNUMBER_NOT_FOUND = 14
SLOCTYPE_NOT_FOUND = 15
TEXT_NOT_FOUND = 16
UNIT_NOT_FOUND = 17.
CASE SY-SUBRC.
WHEN C_RC00.
* alles o.k.
RQM01-MATKL = MARA-MATKL.
RQM01-PRDHA = MARA-PRDHA.
WHEN C_RC10.
MESSAGE E005(QM) WITH P_MATNR.
ENDCASE.
* Beim Material sitzt Loeschvormerkung.
IF NOT MTCOR-LVORM IS INITIAL.
MESSAGE W008(M3).
ENDIF.
ENDFORM. " MATERIAL_CHECK
*& Form MATERIAL_WERK_CHECK
* text
* -->P_AFPO_MATNR text
* -->P_P_CAUFV_WERKS text
FORM MATERIAL_WERK_CHECK USING VALUE(P_MATNR)
VALUE(P_WERK).
*-- local data
DATA : BEGIN OF L_DUMMY_TAB OCCURS 0,
DUMMY(1),
END OF L_DUMMY_TAB.
* Examination only, if materials number and work filled
CHECK ( NOT P_MATNR IS INITIAL
AND NOT P_WERK IS INITIAL ).
* Checking on MARC segment
MOVE C_MARC_SEGMENT TO MTCOM-KENNG.
MOVE P_MATNR TO MTCOM-MATNR.
MOVE P_WERK TO MTCOM-WERKS.
CALL FUNCTION 'MATERIAL_READ'
EXPORTING
SCHLUESSEL = MTCOM
IMPORTING
MATDATEN = MARC
TABLES
SEQMAT01 = L_DUMMY_TAB
EXCEPTIONS
ACCOUNT_NOT_FOUND = 01
BATCH_NOT_FOUND = 02
FORECAST_NOT_FOUND = 03
LOCK_ON_ACCOUNT = 04
LOCK_ON_MATERIAL = 05
LOCK_ON_PLANT = 06
LOCK_ON_SALES = 07
LOCK_ON_SLOC = 08
LOCK_SYSTEM_ERROR = 09
MATERIAL_NOT_FOUND = 10
PLANT_NOT_FOUND = 11
SALES_NOT_FOUND = 12
SLOC_NOT_FOUND = 13
SLOCNUMBER_NOT_FOUND = 14
SLOCTYPE_NOT_FOUND = 15
TEXT_NOT_FOUND = 16
UNIT_NOT_FOUND = 17.
CASE SY-SUBRC.
WHEN C_RC00.
* alles o.k.
RQM01-KZDKZ = MARC-KZDKZ.
RQM01-KZKRI = MARC-KZKRI.
WHEN C_RC11.
MESSAGE E004(QM) WITH P_MATNR
P_WERK.
WHEN C_RC10.
MESSAGE E005(QM) WITH P_MATNR.
ENDCASE.
ENDFORM. " MATERIAL_WERK_CHECK
*& Module FCODE INPUT
* text
MODULE FCODE INPUT.
*& Inserted by CC 01/24/2007
II_VIQMEL-FERTAUFNR = RQM01-FERTAUFNR.
*& End by CC 01/24/2007
PERFORM FCODE USING OK-CODE.
ENDMODULE. " FCODE INPUT
*& Form FCODE
* text
* -->P_OK_CODE text
FORM FCODE USING VALUE(P_FCODE) LIKE SY-TCODE.
CASE P_FCODE.
WHEN C_FCODE_ENT1.
*-- Weiter
SET SCREEN 0.
LEAVE SCREEN.
ENDCASE.
IF SY-UCOMM = 'CANC'.
SET SCREEN 0.
LEAVE SCREEN.
ENDIF.
ENDFORM. " FCODE -
To develope an alv report or module pool and field link.. and effor require
HI,
I want to display the fields with sort functionality with fields
kunnr kna1 table
name1 kna1
and email id from table ADR6 field SMTP_ADDR
my question ison mapping
from kna1 we can get field kunnr and name1
and adrnr
to put in adr6 to fetch email id
can anyoe suggest on select statements link as table kna1 has one unique kunnr
but it can have multiple name1 and adrnr
so how to pick the kunnr ,name 1 and adrnr from table kna1 and map to
adr6 table
as witinn the table kna1 there can be multiple name1 related to one single kunnr
so wil it be like
select kunnr from kna1..into it_kunnr
then select nam1 from table kna2 for all entrirs in It_kunnr
or firse selet kunnr name1 from kna1 into table it_kunnr
pls suggest an appropiat select statament
and i suppose this can be achevied by alv report no need for moudle pool
regards
Aroraopened a new thread with changes subject
-
Regarding Module Pool program!
Hi experts,
I have the following issue.
in my first screen there is username and password input field and two push button. 1. logn .2. change password.
I am getting succesfully logon. and when i click change pwd button it will get old pwd, newpwd, and confirm new pwd in the another screen. (upto this also i am having no issue.)but when giving old pwd , new pwd and confirm new pwd i. in the input field i am unable to change the password moreover getting the error msg what I have handled.I have given the necessary codes.
PROCESS BEFORE OUTPUT.
MODULE STATUS_0100.
PROCESS AFTER INPUT.
field zpasswords-psw module validate_logon_details.
module exit_from_prog AT EXIT-COMMAND.
MODULE USER_COMMAND_0100.
MODULE VALIDATE_LOGON_DETAILS INPUT.
SELECT * FROM ZPASSWORDS INTO WA_PSW WHERE PSW = ZPASSWORDS-PSW.
ENDSELECT.
IF SY-SUBRC <> 0.
MESSAGE E000(ZSMSG).
ENDIF.
ENDMODULE.
MODULE USER_COMMAND_0100 INPUT.
CASE SY-UCOMM.
WHEN 'LOGON'.
SELECT * FROM ZPASSWORDS INTO WA_PSW WHERE PSW = ZPASSWORDS-PSW.
ENDSELECT.
IF SY-SUBRC = 0.
CALL SCREEN 300.
ENDIF.
WHEN 'PSW'. "For change password pushbutton.
SELECT * FROM ZPASSWORDS INTO WA_PSW WHERE PSW = ZPASSWORDS-PSW.
ENDSELECT.
IF SY-SUBRC = 0.
CALL SCREEN 200.
ELSE.
MESSAGE E000(ZSMSG)." wrong entry
ENDIF.
CLEAR SY-UCOMM.
ENDCASE.
PROCESS BEFORE OUTPUT.
MODULE STATUS_0200.
PROCESS AFTER INPUT.
CHAIN.
FIELD : OLDPSW , NEWPSW , CONFIRMPSW
MODULE VALIDATE_PASSWORD.
ENDCHAIN.
MODULE EXIT_FROM_PROG AT EXIT-COMMAND.
MODULE USER_COMMAND_0200.
MODULE USER_COMMAND_0200 INPUT.
CASE SY-UCOMM.
WHEN 'SAVE'.
UPDATE ZPASSWORDS SET PSW = NEWPSW WHERE PSW = OLDPSW.
IF SY-SUBRC = 0.
MESSAGE S001(ZSMSG). "Password Changed Successfully
ENDIF.
WHEN 'BACK'.
LEAVE TO SCREEN 0.
ENDCASE.
CLEAR SY-UCOMM.
MODULE VALIDATE_PASSWORD INPUT.
SELECT * FROM ZPASSWORDS INTO WA_PSW WHERE PSW = OLDPSW.
ENDSELECT.
IF SY-SUBRC = 0.
IF NEWPSW <> CONFIRMPSW.
MESSAGE E003(ZSMSG).
ENDIF.
ELSE.
MESSAGE E004(ZSMSG).
ENDIF.
ENDMODULE.
N.B. Points are assured in case of of helpful reply.
Thanks&Regards
Sarkar
Moderator Message: Use a more meaningful title. Do not tempt responders with points. Put your code between code tags.
Edited by: kishan P on Feb 16, 2011 4:56 PM
Edited by: kishan P on Feb 16, 2011 4:58 PMhI...
There is no FM to Refresh the Fields in a Screen.
Use the CLEAR statement to Clear each variable.
In the PBO module of the Screen use this code.
IF OK_CODE = 'REFRESH'.
CLEAR : WA.
ENDIF.
<b>Reward if Helpful</b>
Maybe you are looking for
-
Exit for automatic creation of line items in VA01
Hello All, I have a requirement wherein I need to create next blank new line item (with predefined line item no) upon creation of one line item. When user opens sales order creation screen there should be default line item (say line item no 10) creat
-
Newbie: First time creating a form
I created a form using LifeCycle. I distributed the form. Now I have to make additional changes. Is there a way to replace certain pages with new ones without losing the fields and drop-downs I have already created. Also, once the form is distributed
-
Is any of this actionable? What should I try next? Exit Code: 7 Please see specific errors and warnings below for troubleshooting. For example, ERROR: DW030, DW050 ... -------------------------------------- Summary ---------------------------------
-
hi expert: i open file saved via system->save->local file-> spreadfile almost line item can be displayed correctly.. but some records are hidden into the description field of previous entry. perhaps some special character exist in description field f
-
Satellite A205-S7458: I can't play games
My boyfriend bought a Sattelite A205-S7458 in US, and after a few weeks trying to like Vista he decided to downgrade to XP, because the games he likes didn't work on Vista. After spending several days trying to find the right drivers, we finnaly mana