Screen Field Color in Module pool
Hi Experts,
I have a requirement like based on the field content i want to change the color to the screen field. I have written code like below. But i'm getting dump.
LOOP AT SCREEN.
IF screen-group1 = 'G02'.
screen-color = 'C411'. -
> Getting dump here
MODIFY SCREEN.
ENDIF.
ENDLOOP.
Please tell me whether it is possible to give color in module pool or not.
Thanks and Regards,
nag.
Hi Sam,
Thanks for ur reply. I have tried using only integers.But i'm not getting color. My code is below
LOOP AT SCREEN.
IF screen-group1 = 'G02'.
screen-color = '411'.
MODIFY SCREEN.
ENDIF.
ENDLOOP.
color is INT4 type rite but we are passing only 3 characters to screen-color.But i didn't color to my field.
Similar Messages
-
How to Add F4 Help To a Screen Field In a Module Pool Program
Hi Friends,
1. How to Add F4 Help To a Screen Field In a Module Pool Program?
2. How to select a single cell in ALV report output for interactive reporting ?
Kindly give code example.
regards,
PradeepHi,
Try using the fm 'F4IF_INT_TABLE_VALUE_REQUEST'.
Refer the link below for selecting single cell.
alv
Reward points if useful.
Regards
Rose -
How to deactivate the screen fields dynamically in Module Pool Program?
Hi guys,
How to <b>activate & deactivate the screen fields</b> of a <b>module pool program</b>
<b>dynamically</b> through program. Like Change mode and display mode in a single
screen.Hi,
Make use of a Variable,say gv_flag, for both Activate and Deactivate functionalities. As many times you hit the same button, change this variable value. For example, let us say first time you hit this button, assign value 'X' to this variable. Second time you hit this button, assign value ' ' to this variable. In PBO based the variable value you have to Activate and Deactivate.
PBO.
if gv_flag = 'X'. " Activate
loop at screen.
if screen-fname = 'ITAB1-MATNR'.
screen-input = '1'.
modify screen.
endif.
endloop.
elseif gv_flag = ' '. " Deactivate
if screen-fname = 'ITAB1-MATNR'.
screen-input = '0'.
modify screen.
endif.
endloop.
endif.
PAI.
case sy-ucomm.
when 'ACDC'. " Activate/Deactivate
if gv_flag = 'X'.
gv_flag = ' '.
else.
gv_flag = 'X'.
endif.
endcase.
thanks,
sksingh -
Validations on the screen fields in a module pool program
Hi all
i am creating a sales order against a purchase order ,i am selecting a PO click on a button to call another screen which has all the mandatory fields of the SO i want validations on the screen fields or the input fields as when i enter the header data and the items data and the partner data from the input serach help that is already enabled on the screen fields ,if there is any mismatch among the fileds and an error message is displayed for example:-" material no 100-100 does not exist for sales area" then only that field where this message is present should be field enabled and the rest of the fields should be field disabled.
also the error message i m displaying is in short text form and not in long text i clicked on it (long text) however how to use it was not known to me .
thanks
varun
Moderator message: please do more research before asking, try solving problems yourself first, look for previous discussions of similar issues, post texts in more readable format, you have been warned several times before.
Edited by: Thomas Zloch on Feb 7, 2012i want to have input search help as if i select sales document type then corresponding sales organizations should appear
This would be quite opposite of what h_vakz does. h_vakz gives Sales document based on Sales org..and you want vice versa. Create a simple SH with
selection method : TVAKZ
AUART as importing only
VKORG as exporting only. So when you enter an AUART you get all VKORG it is defined in. I'm not aware of a standard search help which matches the requirement. If anybody does please help me.
i have header data (only mandatory fields),items data,partner data(all mandatory fields)
and when i select all the header data the search help that is on the material number and partners role and number should appear corresponding to that header data
You will have to be more specific sir..
not able to apply please guide someone
As for that just mention them in SCREEN->ELEMENT LIST->REFERENCES -
Applying search help on the screen fields of a module pool program
hi all
i am creating a sales order against a purchase order i am stuck at applying the search helps
i have header data (only mandatory fields),items data,partner data(all mandatory fields)
i want to have input search help as if i select sales document type then corresponding sales organizations should appear and when i select all the header data the search help that is on the material number and partners role and number should appear corresponding to that header data
i found following search helps as:-
h_vakz and h_mvke
not able to apply please guide someone
thanks
varuni want to have input search help as if i select sales document type then corresponding sales organizations should appear
This would be quite opposite of what h_vakz does. h_vakz gives Sales document based on Sales org..and you want vice versa. Create a simple SH with
selection method : TVAKZ
AUART as importing only
VKORG as exporting only. So when you enter an AUART you get all VKORG it is defined in. I'm not aware of a standard search help which matches the requirement. If anybody does please help me.
i have header data (only mandatory fields),items data,partner data(all mandatory fields)
and when i select all the header data the search help that is on the material number and partners role and number should appear corresponding to that header data
You will have to be more specific sir..
not able to apply please guide someone
As for that just mention them in SCREEN->ELEMENT LIST->REFERENCES -
Selection screen as subscreen in module pool main screen
hello
i having problem with a module pool and a selection screen subscreen , i have my main screen 100 in my module pool
i create a sub screen area , then in my top include i define a seleccion screen as subscreen 150
i define some paramets and select-options ( for the select-options feature is because i choose use the subscreen )
so far here is OK , the problem is when i fill the subscreen data and press a pushbutton define in the main screen ( 100 )
the field are getting cleared ( BTW i call the subscreen in the PBO of the main screen ( 100 ) using call SUBSCREEN SUB_AREA INCLUDING SY-REPID '150'. ) so my question is how i can do for save the data filled in the subscreen ?
thanksi find the solution of my own question:
in the first line of the PAI event of the main screen ( where you call the subscreen ) need add 'call subscreen SUB_AREA_NAME_HERE. -
How many screens are there in module pool
hi gurus
can anyone suggest me
how many screens are there in module pool
thank you
regards
kals.see this link for better understanding of dialog programming/module pool programming.
http://help.sap.com/saphelp_nw04/helpdata/en/9f/db9ce935c111d1829f0000e829fbfe/content.htm
see this
Check the below link:
http://wiki.ittoolbox.com/index.php/FAQ:What_is_module_pool_program_in_abap%3F
http://help.sap.com/saphelp_46c/helpdata/en/35/26b1aaafab52b9e10000009b38f974/content.htm
http://sap.mis.cmich.edu/sap-abap/abap09/sld011.htm
http://sap.mis.cmich.edu/sap-abap/abap09/index.htm
http://www.geocities.com/ZSAPcHAT
http://www.allsaplinks.com/files/using_table_in_screen.pdf
http://help.sap.com/saphelp_webas630/helpdata/en/9f/db9cdc35c111d1829f0000e829fbfe/content.htm
http://www.sapdevelopment.co.uk/dialog/dialoghome.htm
http://www.sap-img.com/
http://help.sap.com/saphelp_46c/helpdata/en/08/bef2dadb5311d1ad10080009b0fb56/content.htm
http://www.sapgenie.com/links/abap.htm
http://help.sap.com/saphelp_nw04/helpdata/en/c9/5472fc787f11d194c90000e8353423/frameset.htm
You can also check the transaction ABAPDOCU which gives you lot of sample programs.
Also you can see the below examples...
Go to se38 and give demodynpro and press F4.
YOu will get a list of demo module pool programs.
One more T-Code is ABAPDOCU.
YOu can find more examples there.
See the prgrams:
DEMO_DYNPRO_TABLE_CONTROL_1 Table Control with LOOP Statement
DEMO_DYNPRO_TABLE_CONTROL_2 Table Control with LOOP AT ITAB
http://www.geocities.com/ZSAPcHAT
http://www.allsaplinks.com/files/using_table_in_screen.pdf
Regards.
Chandru -
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 -
Field validation in Module Pool
Hi,
In my module pool, on main screen there are various fields, now out of these i've to give validation for 4 fields through a drop down field such that:
There are 2 items in my drop down, when 1st item of drop down is clicked then out of 4 fields for which i've to give validation, 2 should be Active (should take input) and other 2s should be inactive.
And if I click the 2nd item of dropdown then there shoud be vice versa(inactive ones should b active now and active ones should be inactive now).
Also got the function module VRM_SET_VALUES & a program DEMO_DYNPRO_DROPDOWN_LISTBOX for dropdown but don't know how can I use. If anybody can tell for either of or for both probs then will be a great help.Hi,
As for the question regarding (de)activating fields:
parameters: pa_list ... "your listbox
data: st_first_two type i value 1, "status of first two fields,
st_last_two type i value 0. "status of last two fields
at selection-screen. "in PAI
"determine status of fields depending of what was choosen
if pa_list = '1st_item'. "if first item picked
st_first_two = 1.
st_last_two = 0.
else. "2nd picked
st_first_two = 0.
st_last_two = 1.
endif.
"now change them
Loop at screen.
if screen-name CS 'First_field' or
screen-name CS 'Secodn_field'.
screen-input = st_first_two. "(de)activate first two fields
elseif screen-name CS 'Third_field' or
screen-name CS 'Fourth field'.
screen-input = st_last_two. "(de)activate last two fields
endif.
modify screen.
endloop.
This way you can in turn activate/deactivate your fields depending of the item picked in the listbox.
As for the question, this fm (VRM_SET_VALUES) is used to populate possible entires in the listbox in PBO (AT SELECTION-SCREEN OUTPUT) which user can later pick. It is usually used to fill data with your custom structure, not the DDIC one. Go through this demo and see step by step how data are populated to listobox (just before screen is displayed).
Also refer [this link|http://sap.niraj.tripod.com/id38.html]. It gives quite good explanation how it should be used.
Regards
Marcin -
Runtime change of field text in module pool
Hi All,
I have a requirement where I have 2 fields in module pool. Based on input of first field the text of second field is decided. i.e. we have to change the text of second field based on value of first screen.
How to handle this.
Edited by: Suchender Dagar on Nov 24, 2010 5:38 AMHi,
Define a variable w_field(20) type c.
Put a input/output field in the second screen ( with the name w_field ) where you want the text and change the attribute of that field by removing the tick input checkbox and then selecting the 2D attribute of tat field, this will make the field as text field.
Then in PBO of the screen screen write the code based on the First field fill the text in the seconf field.
Regards,
Madhukar Shetty -
Custom field added in Module pool is not reflecting in SRM Shopping cart
Hi all,
I have to add a custom field for Plant in the Ship-To address subscreen(BBPSC01) in Shooping cart in SRM.
I have added the field in the program "saplbbp_sc_ui_its" in screen 310.
But I think need to write the HTML code/Java script in HTML template to trigger the code from module pool.
As I am new to this scenario, can anyone please let me know the procedure to follow.
Thanks,
Rakesh.Hello Anubhav,
If your new customer fields are not displayed dynamically, re-generate Dynpro concerned using report BBP_DYNPROS_GENERATE.
Regards.
Lauurent. -
Selection screen regeneration issue in Module pool
Hi experts,
I have designed a module pool in which i have included a selection screen as sub screen , and for the scenario i need to give custom f4 help for the selection field for that i have included logic ,My issue is when ever i am changing other code in the programs (other screen logic) the selection screen is reverting back to normal ...again i have to do the flow logic and screen change of selection screen.
Suggest me how i can avoid this .
Regards,
Siva Prasad.and for the scenario i need to give custom f4 help for the selection field for that i have included logic
was the error, use some AT SELECTION-SCREEN ON VALUE-REQUEST FOR {para|selcrit-low|selcrit-high} or PARAMETERS/SELECT-OPTIONS MATCHCODE OBJECT search_help statement, and your problem will vanish... (Edition of a generated object is hardly ever a good idea and never good practice)
Regards,
Raymond -
Want to know the screens associated with a module pool program ??
Hi,
I have an M type program (module pool), say SAPMF05M. I want to
1) see which transaction code initiated it ??
2) see the screens associated with it ??
how do i achieve this ?? I know just the program name !!
thanksGo to SE80, make sure "program" is in the object list box, enter the program name in the field underneath the object listbox and hit enter. You will see a bunch of folders in the tree structre. There will be one for screens and one for transactions.
Please remember to award points for helpful answers. Thanks.
Regards,
Rich HEilman -
Making screen-input 0 in module pool
Hi all,
I am creating one module pool program in which i am taking some I/O fields
for Input Output both possible...
Now i have also created one push button DISPLAY..
Now when user enter Serial Number and press DISPLAY button all other I/O fields other than Serial Number should fill and become input not possible.
All data coming but i dont know what to do to make input 0.
Is it possible?
Can anyone help me?
Thanks in advance.........need to write under PBO
example :
process on before-output.
module screen.-> double click on module
module screen.
loop at screen.
here write the code.
endloop.
endmodule.
Thanks
Seshu -
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
Maybe you are looking for
-
How can i transfer all my data 250 GB from external hard disk to MAC pro
How can i transfer all my data 250 GB from external hard disk to MAC pro
-
Adding Metadata in Illustrator 10?
Hi All, Fairly new to Illustrator here. I've designed some work for a company that produces organic beauty products, and I need to embed some information within my files - especially before they go to be printed as product labels. I'm using Illustrat
-
Sender JDBC Adapter : Urgent Question
Hi, I am working on a Oracle - XI - R/3 scenario. This scenario is working fine currently. The question that I have is what if I more than 500,000 records existing in the oracle table, then how many records will be picked up by the adapter when it
-
Why can't Apple make The video iPod menu display on your TV screen? I plug my iPod into my suround sound system, have the remote for the iPod and if your sitting on your couch, after watching a movie or song or what ever, you always have to get up to
-
Hi All, My wife has a late 2008 Mac Book 13" it has 45.06GB free memory (after i got rid of a lot of unwanted apps etc..) There is 65GB of the 'Other" on the hard drive, basically everytime she opens anything we get the pin wheel and everything opens