How to make some fields mandatory based on radio button selected
Hi,
As per requirement i have two radio buttons in my screen.
1.update
2.Display.
When the user clicks update then certain fields of selection screen should be made mandatory.
And if the user cliks the Display Radio Button then certain fields should be made mandatory.
How to code for it.
Thanks and Regards,
Smriti
Hi ,
use this code ,
now according to your requirement you make changes to your parameters.
parameters: r1 as radiobutton group g1, " this id you update button
r2 as radiobutton group g1. " this is for display
PARAMETERS: TEST1(10) MODIF ID SC1, " assume these are the fields as parameters.
TEST2(10) MODIF ID SC2,
TEST3(10) MODIF ID SC1,
TEST4(10) MODIF ID SC2.
AT SELECTION-SCREEN OUTPUT.
if g1 = 'X'.
LOOP AT SCREEN.
IF SCREEN-GROUP1 = 'SC1'.
SCREEN-INTENSIFIED = '1'.
MODIFY SCREEN.
CONTINUE.
ENDIF.
IF SCREEN-GROUP1 = 'SC2'.
SCREEN-INTENSIFIED = '0'.
MODIFY SCREEN.
ENDIF.
ENDLOOP.
elseif g2 = 'X'.
LOOP AT SCREEN.
IF SCREEN-GROUP1 = 'SC1'.
SCREEN-INTENSIFIED = '1'.
MODIFY SCREEN.
CONTINUE.
ENDIF.
IF SCREEN-GROUP1 = 'SC2'.
SCREEN-INTENSIFIED = '0'.
MODIFY SCREEN.
ENDIF.
ENDLOOP.
Please let me know if you still need any help.
Thanks and regards,
Rajeshwar
Similar Messages
-
How to make some fields mandatory for a custom screen we have added
Hi All,
Please let me know how can I make some fields mandatory through coding in PBO for only some fields of a screen.
Say if I have 4 fields in my screen(module pool not selection screen) i want to make mandatory 2 fields based on some conditions how to do this? I tried using screen-group but this will make mandatory all the fields of that screen mandatory.
I want only specific fields based on condition in run time.
Regards
MaheshHi Mahesh,
Try this ..
Assign the same group to those fields , say GRP
in PAI
IF <CONDITION>
Loop at screen.
if screen-group1 = 'GRP'.
screen-required = '1'.
modify screen.
endif.
endloop.
ENDIF. -
How to make a field Mandatory in a Table view?
How to make a field Mandatory in a Table view?
The requirement is, the user should not be able to append a new Row, unless and untill he enteres the data in the column SOLD-TO. Now how do i acheive making this field madatory. Normally in Edit form view, we can go in customizing and flag Mandatory, for table view we don't have this option.
Please can anyone of you guide me in this approach?
Jagadish.GHi Jagadish,
have a look in this thread, part of the code you can use in eh_insert method or logic to write enable/disable insert button.
Re: Assignment Block Mandatory
regards
Ismail
Edited by: Ismail Shaik on Oct 21, 2009 11:36 AM -
How to make a field mandatory in billing
How to make a field mandatory in billing document,if m right with the help of incomplition log but how.....
plz reply the full configuration.Hi Mohan,
We normally create a billing document with reference any other document say Order or delivery.
so, all the necessary information in the invoice will be taken from preceeding doucments. Thats way in the order level we check for incompletion log. If any important data is missing in the order level then the succeding documents will not be created.
Thats way in the billing documents all the necessary information will come automatically either from preceeding documents or from master data.
Still you want to make any field mandatory, you can do these by modifieing Billing documents user exists,you can make which ever the fields are mandatory and to be checked before saving. so when you are going to save the invoice, it will check if these fields are maintained or not.
Hope this is clear.
Reward if helpful.
Thanks,
Praveen -
How to make all fields mandatory in sales order T- code VA01 initial screen
Dear all,
how to make all fields mandatory in sales order T- code VA01 initial screen itself
The fields are
Sales Organization
Distribution Channel
Division
Sales Office
Sales Group
Regards,
Amar ReddyHi,
You can use Transaction Variant to achieve this functionality.Please go through the following link which helps you in creating the same.
[Link|http://wiki.sdn.sap.com/wiki/display/Snippets/TransactionVariant-AStepbyStepGuidefor+Creation]
Regards,
Phani Prasad -
Need to make some fields mandatory in standard transaction XK01
HI All,
Is it possiable to make some fields in standard transaction like XK01 mandatory?
or any work around ?
thank in advance for your replies.
Regads,
Riyaz.Hi,
From configuration(SPRO) u can easily make some fields mandatory in XK01. Otherwise create a transaction varition for XK01 using TC SHD0.
Rewards points if helpful.
Regards,
Srinivas Ch -
How to make some fields in ALV tree editable
Hello All,
Can any one tell me how to make some fields in ALV tree editable.
If possible please post some code.
Regards,
Lisa.Hi Lisa,
I want to make 3 fields in the ALV tree editable and update the saved values in ztable.
I tried making the wa_fieldcat-edit = 'X' But in vain.
Also i made the layout fields wa_layout-edit = 'X' and wa_layout-edit_mode = 'X'.
But still the alv tree field appears as display.
As you have mentioned in the post as answered, So please guide me to make the field editable.
I am using oops method.
Please provide me code if any.
Thanks & Regards,
Mozila -
How to make extended field mandatory in Master Agreement
Hello All,
I am new to SAP CLM, and I have requirement where one extended field in master agreement needs to be made as mandatory field.
I tried in extension definition but check box to make it required is disabled and I am unable to find other way to do it.
Can some one help me and Please let me know how make extended fields mandatory in CLM.
Regards,
PrabhatHi
This could be achieved using Page Customization.Go to Setup-> User Interface-> Page Customization, open master agreement object (create new with UI ID:contracts.contract.ui.buyside.default if doesn't exist ) and add a new customization for extended field with Property set to Required.
Regards
Mudit Saini -
How to make some fields disable mode in BAPI?
Dear sir,
I want to know in Bapi, In Import parameters of output display screen as we are entering values i want to make some fields disable mode (as in report program, in output screen, suppose 2 entry fields are der so i need only one and another one in disable mode)how to do in BAPI? please explain with example by taking 2 or 3 predefined tables? and in Bapi how to do ranges programs.. please explain with example? is it posiible in bapi to display the output in ALV_GRID method?
regards
patilHi Rachu Patil,
I think there is no posibility to disable fields in import parameter of bapi but you can select optional check box to make the field as an optional field in import parameter. Like wise you cant set range. If you want to set range than declare two variable for low and high.
Regards,
Harish -
How to make some fields of a view non editable
Hi experts,
I need to make some fields like system user, system time and system date of a view non editable and after saving values for all other editable fields, the system should fill the values for the non editable fields as well.
Kindly help in this regard.I am assuming that you created a maintenance view for your table. Under view fields there is a column called 'Maintenance Attribute for view field' (one character field with 'P' in the column. Set that column value to 'H' for the fields that you want to hide.
You then have to go to SE54, give your maintenance view name, in the menu, 'Environment-->Events' create an event 01 with your own code to fill in those hidden fields. Look with key words 'Table Events' in this forum and you will get a lot of examples. -
How to disable a field on the basis radio button value selected.
hello to all,
i am facing one problem.I have declared two selection screen blocks.
In one i hvae declared two radio button r1 -Fiscal year and r2--Datewise.
And in another selection screen block all i/p fields. like plant. date.year etc.
Now if user select r1-Fiscal year then i/p field - date of second block should be disable.
And if user select r2-Datewise then i/p field - year of second block should be disable.
SELECTION-SCREEN BEGIN OF BLOCK BLK WITH FRAME
TITLE TEXT-002.
PARAMETERS: R1 RADIOBUTTON GROUP RA1 user-command ucomm,
R2 RADIOBUTTON GROUP RA1 DEFAULT 'X'.
SELECTION-SCREEN END OF BLOCK BLK.
selection-screen begin of block b1 with
frame title text-001.
parameters : gjahr like ZSA_DETAIL-gjahr MODIF ID YAR,
aedat like ZSA_DETAIL-aedat MODIF ID DAT,
werks like ZSA_DETAIL-werks .
selection-screen end of block b1.
AT SELECTION-SCREEN on RADIOBUTTON GROUP RA1.
BREAK-POINT.
IF R1 = 'X'. "fiscal
LOOP AT SCREEN.
IF screen-group1 = 'DAT'.
screen-active = 0.
screen-invisible = 1.
MODIFY SCREEN.
ENDIF.
endloop.
ELSEIF R2 = 'X'.
LOOP AT SCREEN.
IF screen-group1 = 'YAR'.
screen-active = 0.
MODIFY SCREEN.
ENDIF.
ENDLOOP.
ENDIF.Hi Shikha,
Regarding your query, when you select a particular radio-button then the fields pertaining to that radio-button should get activated or get displayed, otherwise it should be hidden.
This can be done adding the addition to the Radiobutton 'USER-COMMAND' this will automatically enable-up
the functionality of the fields related to that radiobutton, while disabling the others.
If USER-COMMAND isn't given, then ENTER key serves the purpose.
DATA:
w_carrid LIKE sflight-carrid,
w_connid LIKE sflight-connid.
PARAMETERS:
p_carrid RADIOBUTTON GROUP airl USER-COMMAND airline,
p_connid RADIOBUTTON GROUP airl.
SELECT-OPTIONS:
s_carrid FOR w_carrid,
s_connid FOR w_connid.
INITIALIZATION.
p_carrid = 'X'.
Now enabling desired fields and disabling the others, can be done by the following snippet.
AT SELECTION-SCREEN OUTPUT.
LOOP AT SCREEN.
IF p_carrid EQ 'X'.
IF screen-name CS 'S_CONNID'.
screen-active = 0. " Disable the field S_CONNID
MODIFY SCREEN.
ELSEIF screen-name CS 'S_CARRID'.
screen-active = 1. " Enable the field S_CARRID
MODIFY SCREEN.
ENDIF.
ELSEIF p_connid EQ 'X'.
IF screen-name CS 'S_CARRID'.
screen-active = 0.
MODIFY SCREEN.
ELSEIF screen-name CS 'S_CONNID'.
screen-active = 1.
MODIFY SCREEN.
ENDIF.
ENDIF.
ENDLOOP.
Hope, this would help you solve your problem.
Thankyou,
Zahack. -
How to make a region mandatory based on some conditions using CO Extension?
Dear All,
I want to make Attachments region in a seeded page mandatory, based on some conditions. I am able to make fields mandatory using CO Extension, but i am not able to make the attachments region mandatory. Please help.
Thanks
RajRaj,
I have not tried but check if you could get the rowcount which shows how many attachment are upload or not. Then by checking this throw exception if the rowcount is o.
Thanks
--Anil
http://oracleanil.blogspot.com/ -
How to make a field mandatory in SAP Business one ?
How to make a text field mandatory in SAP Business one?
hi nishant,
check this link
Making fields mandatory
To Set Mandatory Fields in Documents
Jeyakanthan -
Can we make some fields mandatory on CAT5 selection screen ???
Hi Experts,
Can we make some of the fields mandatory on CAT5 selection screen.
I want to make posting period as an mandatory field.
Thanks in advance.
Regards,Use below link :
http://help.sap.com/saphelpnw2004s/helpdata/en/7d/f63a22015111d396480000e82de14a/frameset.htm_
Regards
Ashish -
How to make buttons as disable based on radio button selection in .htm
Hi
I have two radio buttons. So i want that when i select one radio button other buttons should become disable in
.htm in crm webui.
Thanx,
Nawal kishore.I am not sure why u need this .. but if you disable the radio button, user won't be able to change the radio buttons any more!!!
You can do it in this way.
1. go to the radio button attribute of the context node ..
if get_p_xxxx method is present then modify that to include the below code. If not present create the method. see any standard method
CASE iv_property.
WHEN if_bsp_wd_model_setter_getter=>fp_server_event.
rv_value = 'selected'. "remember case
endcase.
2. create a event with the name 'selected'. "" case is important
3. check in do_handle_event if the event is created or not..." if there is not event added in that method, you need to add your method name there...
4. set some flag in the event method which you have to access from the get_i_XXX method(XXX is the radio button attribute).
depending on the flag you make it disable.
Maybe you are looking for
-
How can I insert a logo into my signature but keep the typed signature?
I want to type info & also insert my logo Example: Carl Clouser Director of Sales TRYST Electronic Smoking Products [email protected] 724-679-4212 www.enjoytryst.com www.facebook.com/enjoytryst www.twitter.com/enjoytryst Insert logo here plus I want
-
CW LMS 2.5 deamon manager not starting win2000
For some reason the deamon manager service on this server refuses to start. Here is what I see when trying to start: error 1053. The service did not respond to the start or control request in a timely fashion. I tried to reboot the server, no luck. t
-
Pre-order Street Fighter V to gain special access to the online beta tests!
The world-renowned fighting game series, Street Fighter, is back with its fifth, all-new main entry coming exclusively to PlayStation 4 and Windows PC early next year! For Street Fighter V, Capcom has announced the largest online beta testing in the
-
How can I change the fonts on the initial screen?
How can I change the font and or make it bold on the initial start screen?
-
HT1414 I can't restore my ipod.
I plugged my new ipod touch into my computer to back up some photos and music and then my itunes told me i had to update and restore it. So I followed the steps my itunes told me to and nothing happened. My ipod is displaying a constant image telling