How to bold/color text message in Module pool Programming ?
Hi All ,
I need to bold /color a message in module pool . this message will come when certain conditions satisfied , currently this text message is displaying through variable . I Refereed program DD_STYLE_TABLE , but still not getting desired output . .Is there any other way to achieve the same ?
Could you please help me ?
Thanks in advance !!!!
Regards ,
Mayank K
Hi Mayank,
You can give a try this.
Within the screen you are calling give keyword
Leave to list processing
and then you can give whatever colors which are there in SAP
For making the text bold you can set Format intensified on or off depending on your requirement.
For more details you can refer to programs
program1 : demo_leave_to_list_processing
program2: demo_call_screen_from_list
Regards,
Sandeep Katoch
Similar Messages
-
How to save Custom control records through module pool program ?
Hi guru ,
1. How to save Custom control records through module pool program ?
I wrote multiple lines of record in custom control
Who to save that records ?
thanking you.
Regards,
Subash.Hi,
can refer following code -
IN PAI , CODE is as follows-
*& Form editor_output
FORM editor_output .
NARRATION1 is name of custom controller
IF v_editor IS INITIAL.
Create obejct for custom container
CREATE OBJECT v_custom_container
EXPORTING
container_name = 'NARRATION1'
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.
MESSAGE ID sy-msgid TYPE 'I' NUMBER sy-msgno
WITH sy-msgv1 sy-msgv2 sy-msgv3 sy-msgv4.
ENDIF.
Create obejct for the TextEditor control
CREATE OBJECT v_editor
EXPORTING
wordwrap_mode = cl_gui_textedit=>wordwrap_at_fixed_position
wordwrap_position = line_length
wordwrap_to_linebreak_mode = cl_gui_textedit=>true
parent = v_custom_container
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 'I' NUMBER sy-msgno
WITH sy-msgv1 sy-msgv2 sy-msgv3 sy-msgv4.
ENDIF.
ENDIF.
ENDFORM. " editor_output
getting textdata in internal table as follows
*& Form create_text
FORM create_text .
REFRESH : it_texttable,
it_text.
IF v_doc_number IS NOT INITIAL.
IF v_editor IS NOT INITIAL.
CALL METHOD v_editor->get_text_as_r3table
IMPORTING
table = it_texttable
EXCEPTIONS
error_dp = 1
error_cntl_call_method = 2
error_dp_create = 3
potential_data_loss = 4
OTHERS = 5.
IF sy-subrc <> 0.
MESSAGE ID sy-msgid TYPE sy-msgty NUMBER sy-msgno
WITH sy-msgv1 sy-msgv2 sy-msgv3 sy-msgv4.
ENDIF.
Now, our final text data is in internal table it_texttable.
pls, Reward if found helpful. -
How to take backup of an entire module pool program with code,screen,etc.
Hi experts,
I have some important data in the ides server for which i want to take backup of them.
I have some question regarding the same.
1.How to take backup/download of an entire module pool program with code,screen,etc.
2.How can we take backup/download for a DB table with its structure?
3.How can we take backup of a search help?
Please give some suggestions abt the same.
Regards,
Ashesh.Hi,
May be just for viewing, try downloading from SE80 transaction from the others option.
Here just try issuing the print, it will generate the spool.
Now using the spool, download to your desktop as required. It will have all the information regarding the attributes, fields, elements everything.
The only issue is, may be you need to take all the screens separately.
Regards,
Santhosh. -
How to validate the field values in module pool program?
Hi Guys
I am working with module pool programming.
Here I want to validate the fields like below.
with out filling all the fields if I click SAVE option it has to show a message that all fields has to be filled. This can be done by checking all the fields individually.
I think it can be done through <b>LOOP AT SCREEN ......ENDLOOP</b>. sequence.
If it is possible, can anyone help me?You need to write the Module in between the CHAIN and ENDCHAIN statment in SE51
If you send a warning or error message from a module <mod> that you called using a FIELD statement as follows:
CHAIN.
FIELD: <f1>, <f 2>,...
MODULE <mod1>.
FIELD: <g1>, <g 2>,...
MODULE <mod2>.
ENDCHAIN.
all of the fields on the screen that belong to the processing chain (all of the fields listed in the field statements) are made ready for input again. Other fields are not ready for input. Whenever the MODULE statement appears within a processing chain, even if there is only one FIELD attached to it, all of the fields in the chain (not only the affected field) are made ready for input again, allowing the user to enter new values. If the fields in the processing chain are only checked once, the PAI processing continues directly after the FIELD statement, and the preceding modules are not called again.
Look at the DEMO program DEMO_DYNPRO_FIELD_CHAIN.
ashish -
How to change the logon language in module pool program?
Hello All,
I had created a module pool program and had desiged a screen.
When i am logged in English language i am able to see them in english as per the requirement it is working fine.
But the requirement is wen i am logged in DE then the selection-screen texts should show in English and not in German.
Kindly give me a solution for this.
Thanks & Regards,
Rajesh KumarHi Rajesh,
This problem is because you have maintained a standard dictionary fields on selection screen and all the standard dictionary fields are maintained in DE language, on the screen layout, go to the attributes of that particular text field, there is a option MODIFIZ for dictionary fields (it is a drop down), selection F TEXT, now whatever the text u will define, it will remain same for all the languages, once u do this then u again login in DE,l u will see the text maintained by u and not the DE text.
Do reply if problem still persist.
point if useful.
Rohit G
Edited by: Rohit Gaharwar on Aug 11, 2009 1:24 PM
Edited by: Rohit Gaharwar on Aug 11, 2009 1:30 PM
Edited by: Rohit Gaharwar on Aug 11, 2009 1:36 PM
Edited by: Rohit Gaharwar on Aug 11, 2009 1:36 PM
Edited by: Rohit Gaharwar on Aug 11, 2009 1:37 PM
Edited by: Rohit Gaharwar on Aug 11, 2009 1:38 PM -
Error message in Module Pool program
Hi folks,
I have developed a module pool program for a custom screen. while entering data on the screen,
it throws a error message for a wrong data entry.But, even after cliking enter, the error message coming repeatedly and the screen is disabled.I havent inculded the screen fields in between CHAIN-ENDCHAIN.Is this the reason for the bug. If so, i have approximately 50 fields on my screen.Should i keep all those fields in between CHAIN-ENDCHAIN. Pls suggest me...
Thanks in advance,
Shyam.Hi Shyam,
Please find the LInk below
Hope this is help full
[Error Message|Re: chain endchain]
Thanks
kalyan -
How to make a fld mandatory in module pool program?
I need help on following 2 things
I have module pool program created, in that many screen subscreens created.
1.I want to make a field mandatory
second one is, I have a general tab and data tab.
General tab screen - 2101
Data tab = 2102
In general tab, I have edited the values (change mode), when change the values and try to save it,
It is holding old value.but If i exucute the transaction once again, it is showing the changed value(new value)
For ex: there is a date field value is 03/08/2009
If I change this to 03/09/2009 and press on Save button from the standard menu, still it is showing the value 03/08/2009. but I execute this transaction once again it is showing the value as 03/09/2009
I will be thankful if someone helps me hereHi Chitra,
Go to the properties of the filed select program tab and say input required.
then you will get the problem solved.
For second one actually its saving but not displaying the saved value at the same time ,
for this you write the select statement after saving , so that once save is execute m, select statement also will execute and it will display the newly saved value.
so after saving imdeatly u write the select statement.
like case sy-ucomm.
when 'SAVE'.
insert ztable.
select filed from z table.
endcase.
let me know if ur problem solved.
Regards
Rajendra -
How to get tree structure navigation in module pool program
please send me a sample code for getting tree structure navigation in a screen in module pool program.
ex.
masters
itemsdo a chain and endchain on the fields.Then insert the fields in to the required database.
-
How to find out no of customize module pool program in SAP
Hi All,
I want to find out number of customize module pool program, Workflow, number of changes made to standard SAP objects (SPAU/SPDD in our SAP system
Regards
SagarJoin the table with TRDIR to find module-pool program (TRDIR-SUBC = 'M')
Regards,
Raymond
Aravind. R was faster...
Edited by: Raymond Giuseppi on Jun 18, 2009 12:56 PM -
How to display LONG TEXT STRING in Module Pool Screen ?
Hi Experts,
I want to display long text string, on screen designed through module pool(SE51). I tried to display through input/output field , but it displays it in SINGLE LINE and i have to scroll all through to view all string.
I want to display it in rectangular format . It doesnt allow me to set HEIGHT of component.
Please provide solution.
Thanks in advance.
Regards
DeepakThis is the program where u can get the WA_THEAD from other program like report and trying to display and modifying that text. U can do instead of WA_THEAD u can generate here itself and use also
*& Module pool ZMP_LTEXT *
PROGRAM ZMP_LTEXT .
TABLES: STXL.
*& Module STATUS_9000 OUTPUT
MODULE STATUS_9000 OUTPUT.
CONSTANTS:line_length type i value 132.
DATA:g_editor type ref to cl_gui_textedit,
g_editor_container type ref to cl_gui_custom_container,
CONT1 type scrfname value 'CONT1',
g_repid like sy-repid,
g_ok_code like sy-ucomm,
g_mytable(132) type c occurs 0,
g_mycontainer(30) type c ,
v_result(256) type c,
g_head like thead,
it_line type table of tline with header line,
wa_stxl type stxl.
DATA : BEGIN OF IT_THEAD1,
ICON TYPE ICON-ID.
INCLUDE STRUCTURE STXL.
DATA : END OF IT_THEAD1.
DATA : IT_THEAD LIKE TABLE OF IT_THEAD1,
WA_THEAD LIKE LINE OF IT_THEAD.
IMPORT WA_THEAD FROM MEMORY ID 'ABCD'.
select SINGLE * from STXL into wa_stxl
where tdname = '00006000156500000002'.
SELECT SINGLE * from STXL into wa_stxl
where tdname = WA_THEAD-TDNAME
AND TDID = WA_THEAD-TDID
AND TDOBJECT = WA_THEAD-TDOBJECT
AND TDSPRAS = WA_THEAD-TDSPRAS.
IF SY-SUBRC NE 0.
MESSAGE 'NO RECORD EXIST' TYPE 'E'.
ENDIF.
MOVE-CORRESPONDING WA_STXL TO G_HEAD.
SET PF-STATUS 'STATUS'.
SET TITLEBAR '001'.
if g_editor is initial.
CREATE OBJECT G_EDITOR_CONTAINER
EXPORTING
PARENT =
CONTAINER_NAME = CONT1
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.
MESSAGE ID SY-MSGID TYPE SY-MSGTY NUMBER SY-MSGNO
WITH SY-MSGV1 SY-MSGV2 SY-MSGV3 SY-MSGV4.
ENDIF.
CREATE OBJECT G_EDITOR
EXPORTING
MAX_NUMBER_CHARS =
STYLE = 0
WORDWRAP_MODE = cl_gui_textedit=>wordwrap_at_fixed_position
for to fix number of characters in row to 132 characers
WORDWRAP_POSITION = line_length
WORDWRAP_TO_LINEBREAK_MODE = cl_gui_textedit=>true
for the word to break to next line if it dont fit in line
FILEDROP_MODE = DROPFILE_EVENT_OFF
PARENT = G_EDITOR_CONTAINER
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.
REFRESH g_mytable.
MOVE: WA_THEAD-TDNAME TO STXL-TDNAME,
WA_THEAD-TDID TO STXL-TDID,
WA_THEAD-TDOBJECT TO STXL-TDOBJECT,
WA_THEAD-TDSPRAS TO STXL-TDSPRAS.
CALL FUNCTION 'READ_TEXT'
EXPORTING
CLIENT = SY-MANDT
ID = wa_stxl-tdid
LANGUAGE = wa_stxl-tdspras
NAME = wa_stxl-tdname
OBJECT = wa_stxl-tdobject
ARCHIVE_HANDLE = 0
LOCAL_CAT = ' '
IMPORTING
HEADER =
TABLES
LINES = it_line
EXCEPTIONS
ID = 1
LANGUAGE = 2
NAME = 3
NOT_FOUND = 4
OBJECT = 5
REFERENCE_CHECK = 6
WRONG_ACCESS_TO_ARCHIVE = 7
OTHERS = 8
IF SY-SUBRC <> 0.
MESSAGE ID SY-MSGID TYPE SY-MSGTY NUMBER SY-MSGNO
WITH SY-MSGV1 SY-MSGV2 SY-MSGV3 SY-MSGV4.
ENDIF.
LOOP AT IT_LINE INTO V_RESULT.
APPEND V_RESULT TO G_MYTABLE.
ENDLOOP.
CALL METHOD G_EDITOR->SET_TEXT_AS_R3TABLE
EXPORTING
TABLE = G_MYTABLE
EXCEPTIONS
ERROR_DP = 1
ERROR_DP_CREATE = 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.
endif.
ENDMODULE. " STATUS_9000 OUTPUT
*& Module USER_COMMAND_9000 INPUT
MODULE USER_COMMAND_9000 INPUT.
CASE SY-UCOMM.
REFRESH G_MYTABLE[].
REFRESH IT_LINE[].
CLEAR V_RESULT.
WHEN 'SAVE'.
CALL METHOD G_EDITOR->GET_TEXT_AS_R3TABLE
EXPORTING
ONLY_WHEN_MODIFIED = FALSE
IMPORTING
TABLE = G_MYTABLE
IS_MODIFIED =
EXCEPTIONS
ERROR_DP = 1
ERROR_CNTL_CALL_METHOD = 2
ERROR_DP_CREATE = 3
POTENTIAL_DATA_LOSS = 4
others = 5
IF SY-SUBRC <> 0.
MESSAGE ID SY-MSGID TYPE SY-MSGTY NUMBER SY-MSGNO
WITH SY-MSGV1 SY-MSGV2 SY-MSGV3 SY-MSGV4.
ENDIF.
LOOP AT G_MYTABLE INTO V_RESULT.
APPEND V_RESULT TO IT_LINE.
ENDLOOP.
CLEAR V_RESULT.
CALL FUNCTION 'SAVE_TEXT'
EXPORTING
CLIENT = SY-MANDT
HEADER = G_HEAD
INSERT = ' '
SAVEMODE_DIRECT = 'X'
OWNER_SPECIFIED = ' '
LOCAL_CAT = ' '
IMPORTING
FUNCTION =
NEWHEADER =
TABLES
LINES = IT_LINE
EXCEPTIONS
ID = 1
LANGUAGE = 2
NAME = 3
OBJECT = 4
OTHERS = 5
IF SY-SUBRC <> 0.
MESSAGE ID SY-MSGID TYPE SY-MSGTY NUMBER SY-MSGNO
WITH SY-MSGV1 SY-MSGV2 SY-MSGV3 SY-MSGV4.
ENDIF.
REFRESH G_MYTABLE[].
REFRESH IT_LINE[].
CLEAR V_RESULT.
WHEN 'BACK' OR 'CANCEL' OR 'EXIT'.
LEAVE TO SCREEN '0'.
*CALL SCREEN '0'.
WHEN OTHERS.
ENDCASE.
*G_OK_CODE = SY-UCOMM.
*CLEAR SY-UCOMM.
ENDMODULE. " USER_COMMAND_9000 INPUT -
How to pass the field value from module pool program to smartform using submit?
// AT pai of module pool pgm i entered the following: here gv_orderid is my value to be available at smart form(driver pgm) & zmusic_store_smf is the driver program of my smartform.
gv_orderid= wa-itemid./
SUBMIT ZMUSIC_STORE_SMF VIA SELECTION-SCREEN
WITH p_order = gv_orderid
AND RETURN.
//AT driver pgm(zmusic_store_smf):
START-OF-SELECTION.
CALL FUNCTION 'SSF_FUNCTION_MODULE_NAME'
EXPORTING
formname = 'ZMUSIC_SMARTFORM1'
* VARIANT = ' '
* DIRECT_CALL = ' '
IMPORTING
fm_name = lv_form
EXCEPTIONS
no_form = 1
no_function_module = 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.
CALL FUNCTION lv_form
EXPORTING
* iv_orderid = is_purchase_item-zorder_id.
iv_orderid = gv_orderid.
// here i'm trying to call my smartform('ZMUSIC_SMARTFORM1') from this driver pgm but unable to access the value of gv_orderid please help me out with this.Declare the gv_orderid in modulepool program.
And Declare the parameter as import parameter in smartform.
CALL FUNCTION lv_form
EXPORTING
* ARCHIVE_INDEX =
* ARCHIVE_INDEX_TAB =
* ARCHIVE_PARAMETERS =
* CONTROL_PARAMETERS =
* MAIL_APPL_OBJ =
* MAIL_RECIPIENT =
* MAIL_SENDER =
* OUTPUT_OPTIONS =
* USER_SETTINGS = 'X'
i_input = gv_orderid
* IMPORTING
* DOCUMENT_OUTPUT_INFO =
* JOB_OUTPUT_INFO =
* JOB_OUTPUT_OPTIONS =
* EXCEPTIONS
* FORMATTING_ERROR = 1
* INTERNAL_ERROR = 2
* SEND_ERROR = 3
* USER_CANCELED = 4
* OTHERS = 5 -
How to create a top include for module pool program
hi all..
I want to add my global declarations in one top inlcude.. There are so many other includes in my pgm. But how can i create top include explicitly. Also I have one normal report pgm attached with this module pool.hi Cynthia ,
there are two ways of creating a top include at your situation ,
1) Insert an include <Prog name >TOP in your mpool program and cut n paste your declarations there .. check if this works ...
2)else .. create another m pool program in SE80 , while creating a pop up will ask for with TOP include ... check mark that and then proceed ..
anything of these two will work ...
Reward if helpful !!
Regards,
Ranjita -
How to place multiple list box in Module Pool Program having same option.
I have a screen. I want to place multiple i/o box with listbox option having 10 option of each . Is it possible ?
Hi Manoj,
Sorry, did not got you. You mean list box with 10 options, just this?
Or Cascading list box?
regards,
Archer -
How to create a ListBox in module pool program in 3.1i system ?
Hi All,
How to create a ListBox of type module pool program in 3.1i system ?
when i tried creating, the listbox option is disabled.
Thanks in advance.
Edited by: gulab zehra on Aug 20, 2009 1:26 PMHi,
please go through this...
LIST BOX
Drop down list box can be created in a dialog screen(SE51) as well as selection screen.
In screen painter to create a input/output field into list box we use 'L" as a value for dropdown attribute for the i/o field. In screen painter to determine the type of method that will be used to fill the value list we use the attribute value list. If it is blank, the value list will be filled by the first column of the input help assigned to the screen field. This input help can be defined in the ABAP Dictionary, on screen using SELECT,VALUES screen statements or in event POV (PROCESS ON VALUE-REQUEST ) and the input help that will be passed to the field should consists of 2 columns ,the key column is filled automatically by the system. SAP recommends value list field should be blank.
or
The value can be 'A' meaning that the value list will be filled in the event PBO(PROCESS BEFORE OUTPUT) or before the screen is displayed.In this method we use function module VRM_SET_VALUES to fill the values and pass it to the i/o field. If a function code is attached to the list box the selection of a value triggers a PAI otherwise PAI will not trigger. LIST BOX in SELECTION SCREEN
List Box is created in selection screen using PARAMETERS statement with
AS LISTBOX addition other attributes like VISIBLE LENGTH (width of listbox) can be specified with the declaration. PARAMETERS name AS LISTBOX VISIBLE LENGTH n.
The function module VRM_SET_VALUES is used to fill the value list associated with a List Box .This FM uses types which are declared in type group VRM. So we should declare TYPE-POOLS VRM before using this FM.
Some important types declared in the VRM type group are
VRM_ID
It refers to the name of the input/output field associated with list box
VRM_VALUES
It refers to the internal table consisting of two fields TEXT(80C) and KEY(40)C
that will be used to create the list values.
CALL FUNCTION 'VRM_SET_VALUES'
EXPORTING
ID = name of screen element, it is of TYPE VRM_ID
VALUES = internal table containing values, of TYPE VRM_VALUES
Thanks
Ashu Singh -
COPY THE STANDARD SAP MODULE POOL PROGRAM
HOW I CAN COPY THE STANDARD SAP MODULE POOL PROGRAM ((INCLUDING SCREENS) INTO Z REPORT?
Hi,
Go to transactionSE38 ABAP Editor.Type the program name.Click copy.It will ask whether you want copy documentation,screens,etc.,
Check mark it.
Maybe you are looking for
-
iit's ios8 5g 32G I have no idea what to do now please help
-
Problems with iWS6.0 SP4 after JDK change / upgrade
Solaris8 SPARC iPlanet 6.0 WebServer SP4 I recently upgraded from JDK 1.3.1_02 to JDK 1.3.1_07 . In both cases .... the JDK was installed at /usr/j2se. iPlanet 6.0 SP4 was already using JDK 1.3.1_02 before ( /usr/j2se ). Now after the JDK upgrade, in
-
Running GoldenGate against Oracle 11g Standard Edition?
We're looking to run Oracle GoldenGate against an Oracle 11g Standard edition database to another Oracle 11g DB also on Standard. I've been reading though the documents and they talk of Oracle to Oracle using XStreams which is part of Streams. But it
-
Hi, I need to know about how and which situations we used proxyies in sap PI 7.1 Please help me. I am new to this topic. Thanks, Seenu.
-
Printing multiple photos onto one page
Sorry, fairly new to PSE9! Have a group of photos I need to print to actual size (3cm x 4cm) to go into a photo frame. They are all cropped and ready to go but there doesn't seem to be an option to print multiple images onto one page at a custom siz