Make fields active on radiobutton selection

Hello all,
I have two radiobuttons and two fields.When I select first radiobutton, field1 should be active and when I select second radiobutton field2 should be active.I am able to achieve this using at selection screen output event.But the problem is that when I select first radiobutton, field1 should be mandatory and if I switch to second radiobutton from the first one, field2 should be mandatory. When I switch from radiobutton 1 to radiobutton 2, the validation for the field2 is kicked off even before the field is avaiable for input.How to achieve this?
Thanks
Sandeep

hi ,
*& Report  ZVENKATTEST0
REPORT  ZVENKATTEST0.
TABLES:MARA.
SELECT-OPTIONS:S_TEST1 FOR MARA-MATNR MODIF ID M1 ,
               S_TEST2 FOR MARA-MEINS MODIF ID M2 .
PARAMETERS:P_RAD1 RADIOBUTTON  GROUP G1 USER-COMMAND UC1 DEFAULT 'X',
           P_RAD2 RADIOBUTTON GROUP G1 ,
           P_RAD3 RADIOBUTTON GROUP G1 .
AT SELECTION-SCREEN OUTPUT .
  LOOP AT SCREEN.
    IF P_RAD1 = 'X'.
      IF SCREEN-NAME = 'S_TEST1-LOW' .
        SCREEN-INPUT = '0'.
        MODIFY SCREEN.
      ENDIF.
      IF SCREEN-NAME = 'S_TEST1-HIGH' .
        SCREEN-INPUT = '0'.
        MODIFY SCREEN.
      ENDIF.
      IF SCREEN-NAME = 'S_TEST2-LOW' .
        SCREEN-INPUT = '0'.
        MODIFY SCREEN.
      ENDIF.
      IF SCREEN-NAME = 'S_TEST2-HIGH' .
        SCREEN-INPUT = '0'.
        MODIFY SCREEN.
      ENDIF.
   ENDIF.
      IF P_RAD2 = 'X'.
        IF SCREEN-NAME = 'S_TEST1-LOW' .
          SCREEN-INPUT = '0'.
          MODIFY SCREEN.
        ENDIF.
        IF SCREEN-NAME = 'S_TEST1-HIGH' .
          SCREEN-INPUT = '0'.
          MODIFY SCREEN.
        ENDIF.
      ENDIF.
        IF P_RAD3 = 'X'.
          IF SCREEN-NAME = 'S_TEST2-LOW' .
            SCREEN-INPUT = '0'.
            MODIFY SCREEN.
          ENDIF.
          IF SCREEN-NAME = 'S_TEST2-HIGH' .
            SCREEN-INPUT = '0'.
            MODIFY SCREEN.
          ENDIF.
        ENDIF.
     ENDLOOP.
regards,
venkat.

Similar Messages

  • To suppress certain fields based on radiobutton selection

    hi experts,
    I am having the requirement that on selection of presentation server(radio button) i need to suppress some fields like file path and name in application server(radio button) which are mandatory when application server is selected.
    Now my problem is if I leave the fields in application server blank and select presentation server then it is asking to fill in all required fields.
    Here is the code i am using:
    Selection Screen                                                    *
    SELECTION-SCREEN BEGIN OF BLOCK b1 WITH FRAME TITLE text-t08.
    *FOR APPLICATION SERVER FILE
    PARAMETERS: po_appln RADIOBUTTON GROUP rad1 DEFAULT 'X' USER-COMMAND upload,
                po_ipath TYPE filepath-pathintern  OBLIGATORY MODIF ID app,
                po_ifile TYPE rlgrap-filename       OBLIGATORY MODIF ID app.
    SELECTION-SCREEN SKIP 1.
    *FOR PRESENTATION SERVER FILE
    PARAMETERS: po_dsktp RADIOBUTTON GROUP rad1,
                po_dfile TYPE rlgrap-filename     OBLIGATORY MODIF ID prn.
    SELECTION-SCREEN END OF BLOCK b1.
    AT SELECTION-SCREEN OUTPUT.
      PERFORM modify_screen.
    form MODIFY_SCREEN .
    *When application server radio button is checked
      LOOP AT SCREEN.
        IF po_appln EQ  'X' AND screen-group1 EQ 'PRN'.
          screen-output = '0'.
          screen-active = '0'.
          screen-input  = '0'.
        ENDIF.
        IF po_appln EQ  'X' AND screen-group1 EQ 'APP'.
          screen-input  = '1'.
        ENDIF.
    *When presentation server radio button is checked
        IF po_dsktp EQ 'X' AND screen-group1 EQ 'APP'.
          screen-output = '0'.
          screen-active = '0'.
          screen-input  = '0'.
        ENDIF.
        IF po_dsktp EQ 'X' AND screen-group1 EQ 'PRN'.
          screen-input  = '1'.
        ENDIF.
        MODIFY SCREEN.
      ENDLOOP.
    endform.         
    Can some one please help me

    Hi,
    Remove the obligatory extension in the selection-screen. Then the mandatory check will not be done when you select the radio-button.
    To handle the mandatory check of the path and file, do the checking in the event 'AT SELECTION-SCREEN'
    if sscrfields-ucomm = 'ONLI'. (Declare TABLES: SSCRFIELDS in the data declarations)
    if ipath is initial.
    message E001(z...)  with 'Please enter a file path'.
    endif.
    Regards,
    Vidya Chowdhary A.

  • Make fields invisible based on selection in module pool screen

    I have a several fields in my module pool screen.
    There i have a box called Ref Obj.
    Inside the box i have fields a b c d e f.
    suppose my input has parameter 1.
    I need to show only fielda a and b inside the box
    suppose my input has parameter 2.
    I need to show only fielda c and d inside the box
    suppose my input has parameter 3.
    I need to show only fielda e and f inside the box
    suppose my input has parameter 4.
    I should not show any fields and box should be invisible.
    I would appreciate if any one could help me regarding this
    Thanks in advance

    hi,
    go through this code, and make the required changes according to u'r requirement but the logic is same.
    TABLES: mara , lfa1.
    SELECTION-SCREEN: BEGIN OF BLOCK b1 WITH FRAME.
    PARAMETERS: p_matnr LIKE mara-matnr DEFAULT 'M633640000' MODIF ID m1,
                p_ersda LIKE mara-ersda DEFAULT '30.06.2004' MODIF ID m2,
                p_aenam LIKE mara-aenam DEFAULT 'DOVIND' MODIF ID m3,
                p_matkl  LIKE mara-matkl DEFAULT '0000' MODIF ID m4,
                p_meins LIKE mara-meins DEFAULT 'ST' MODIF ID m5,
                p_mbrsh LIKE mara-mbrsh DEFAULT 'M' MODIF ID m6,
                p_vpsta LIKE mara-vpsta DEFAULT 'KV' MODIF ID m7.
    SELECTION-SCREEN: END OF BLOCK b1.
    SELECTION-SCREEN: BEGIN OF BLOCK b2 WITH FRAME.
    PARAMETERS: p_lifnr LIKE lfa1-lifnr DEFAULT 5070001063 MODIF ID s1 ,
                p_land1 LIKE lfa1-land1 DEFAULT 'FR' MODIF ID s1,
                p_name1 LIKE lfa1-name1 DEFAULT 'HONDA' MODIF ID s3,
                p_ort01 LIKE lfa1-ort01 DEFAULT 'PARIS' MODIF ID s4.
    SELECTION-SCREEN: END OF BLOCK b2.
    AT SELECTION-SCREEN OUTPUT.
      LOOP AT SCREEN.
        IF screen-group1 = 'M1' .
          screen-input = 0.
          MODIFY SCREEN.
        ELSE.
          IF screen-group1 = 'M2' .
            screen-invisible = 1.
            MODIFY SCREEN.
          ELSE.
            IF screen-group1 = 'M3' .
              screen-intensified = 1.
              MODIFY SCREEN.
            ELSE.
              IF screen-group1 = 'M5' .
                screen-length = 10.
                MODIFY SCREEN.
              ELSE.
                IF screen-group1 = 'M6' .
                  screen-active = 0.
                  MODIFY SCREEN.
                ELSE.
                  IF screen-group1 = 'M7' .
                    screen-display_3d = 1.
                    MODIFY SCREEN.
                  ELSE.
                    IF screen-group1 = 'M4' .
                      screen-output = 0.
                      MODIFY SCREEN.
                    ELSE.
                      IF screen-group1 = 'S1' AND
                      screen-name = 'P_LIFNR'.
                        screen-values_in_combo = 1.
                        MODIFY SCREEN.
                      ELSE.
                        IF screen-group1 = 'S1' AND
                        screen-name = 'P_LAND1'.
                          MODIFY SCREEN.
                        ENDIF.
                      ENDIF.
                    ENDIF.
                  ENDIF.
                ENDIF.
              ENDIF.
            ENDIF.
          ENDIF.
        ENDIF.
      ENDLOOP.
    <b>please reward points if helpfull.</b>
    with regards,
    radhika kolluru.

  • Change type field active mode while selecting Change number type

    Dear All,
    Our requirement is to get the list of Change type in the CC01 T-code when we click the change master. When we select ECR then we are getting the change list of change type. But, when we select the change master as type, then change type is coming as grey field. So we want the list of change type in change master
    Please suggest
    Regards
    Honyal

    Any input ?????????
    please
    Regards
    Honyal

  • 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

  • Is it possible to make a fillable form have variable fields - so if you select a radio button it triggers a different form field to be seen depending on which radio button is selected??

    Is it possible to make a fillable form have variable fields - so if you select a radio button it triggers a different form field to be seen depending on which radio button is selected??

    Yes, one needs to use some custom JavaScript code to control the other fields' properties.
    Disabling (graying-out) Form Fields by Thom Parker

  • How to make field ( F110V-LIST1 ) mandatatory in free selection tab of F110

    hi
    How to make field ( F110V-LIST1 ) mandatatory in free selection tab of F110
    regards,
    Billa

    Hi,
    Standard transaction variant is not possible ,i dont want to use as zf110.
    Regards,
    Billa
    Edited by: Billa Mahe on Sep 3, 2010 3:14 PM

  • Make NW-Activity Userfield Label appear as Choose Field in capacity repts.

    Hi Gurus
    Can you guys let me know, how to make " Userfield Label (given name)  in a Network Actvity (internal) appear as Choose Field in capacity repts , (ex:CM07).
    Example:
    1) In SPRO I did give ALPHA as label/name for User Defined Text Field (USR003) for NW Activity.
    2) I did find above user field, active and available for postings in NWA. I now maintained some text in this user field it for some internal activity (that having a Work Center and Capacity Planned).
    3) When I run one of the capacity reports Ex: CM07, and try to access user fields from choose fields option, what I want is that this User Field to appear with its given label/name ALPHA, rather as it currently appearing as User Fld char (10).
    I appreciate for your help in resolving my issue.
    Regards
    Madhukar

    Hi Ahmed,
    You can achieve this by using creating individual capacity for category type.
    Steps:-
    1.Go to Cr02 define capacity category 001 .
    2.Now double click on capacity category it will open its header details.
    3.Now assign individual capacity this will appear in project. as shown
    5.In project u can assign same in capacity.
    Reward if helpfull.
    Thanks
    Suraj Prakash

  • Hiding Screen fields in a Report selection screen

    Hi Experts,
    I have a requirement to hide/disable  screen fields in a report selection screen when the user clicks on some radio buttons .
    Here is the scenario,
    1) There are 4 radio buttons four radiobuttons in one group on the selection screen:--  
    Block no:1
    PARAMETER: r_not  TYPE c RADIOBUTTON GROUP a1 DEFAULT 'X'.
    PARAMETER: r_prgs TYPE c RADIOBUTTON GROUP a1.
    PARAMETER: r_remv TYPE c RADIOBUTTON GROUP a1.
    PARAMETER: r_noresp TYPE c RADIOBUTTON GROUP a1.
    2) Based on the user clicking/selecting the radio buttons no.2,3 nad 4 i need to hide some fields in the other selection block
    in the selection screen.The parameters are as follows:
    Block no:2( These fields need to be hidden/disabled)
    PARAMETER: r_occ(3) TYPE c OBLIGATORY DEFAULT '1'.
    PARAMETER: r_and TYPE c RADIOBUTTON GROUP g1.
    PARAMETER: r_or  TYPE c RADIOBUTTON GROUP g1.
    PARAMETER: r_days(3) TYPE c OBLIGATORY DEFAULT '1'.
    Thanks

    Contd.....
    AT SELECTION-SCREEN.
      CASE SSCRFIELDS-UCOMM.   
          "When Customer button is clicked set flag 1
        WHEN 'FC01'.
          L_FLAG = '1'.
          "When Sales Order button is clicked set flag 2
        WHEN 'FC02'. "Sales order
          L_FLAG = '2'.
          "When Execute button is clicked set flag 4
        WHEN OTHERS.
          L_FLAG = '4'.
      ENDCASE.
    AT SELECTION-SCREEN OUTPUT.
    CASE L_FLAG.
        WHEN '1'.  "When Customer button is clicked
          LOOP AT SCREEN.
            "Set the Production and Customer Block as inactive
            IF  SCREEN-GROUP1 = 'BL1' OR SCREEN-GROUP1 = 'BL3'.
              SCREEN-ACTIVE = '0'.
              MODIFY SCREEN.
            ENDIF.
          ENDLOOP.
        WHEN '2'. "When Sales Order button is clicked
          LOOP AT SCREEN.
            "Set the Production and Customer Block as inactive
            IF  SCREEN-GROUP1 = 'BL1' OR SCREEN-GROUP1 = 'BL2'.
              SCREEN-ACTIVE = '0'.
              MODIFY SCREEN.
            ENDIF.
          ENDLOOP.
        WHEN '3'.   "When Refresh button is clicked
          LOOP AT SCREEN.
            "Set the all Blocks as active
           IF  SCREEN-GROUP1 = 'BL2' OR SCREEN-GROUP1 = 'BL3' OR SCREEN-GROUP1 = 'BL1'.
              SCREEN-ACTIVE = '1'.
              MODIFY SCREEN.
            ENDIF.
          ENDLOOP.
        WHEN OTHERS."When Execute button is clicked
          "Set the Sales order and Customer Block as inactive
          LOOP AT SCREEN.
            IF  SCREEN-GROUP1 = 'BL2' OR SCREEN-GROUP1 = 'BL3'.
              SCREEN-ACTIVE = '0'.
              MODIFY SCREEN.
            ENDIF.
          ENDLOOP.
      ENDCASE.
    ENDFORM.      

  • Can I make the parameter supports multiple selection and editable at the same time?

    Hi, 
    I am building my report using SQL Server Report builder 3.0. All the parameters are added to the report
    by the builder. When the user access the report by browser, he can change the parameter value and click "view report" button to load the report from the database.
    For one of the parameter, I want to provide user the ability to select frequently used value as multiple
    selection, and meanwhile let them able to edit the value if the preloaded selection doesn't contain what he wants.
    Is it possible to archive this goal using report builder?
    Thanks!

    You cant have this functionality using standard report viewer. An approximate work around can be implemented as follows.
    Have two parameters one based on your current parameter values (dropdown) and another one without any available values set and default set to NULL (Set Allow Null value property and pass Null as default value). This parameter will appear as disabled textbox
    with NULL checkbox checked. 
    Now in your code behind which gives you first parameter's values Add one more value say <None Of Values> and set value as some default value (-1 if int or just a random string value).
    Now in the value for second parameter set a expression like below
    =IIF(Parameters!FirstParam.Value ="<Select None>","",Nothing)
    This will make sure second parameter gets activated when you select option <none> from first. Then you can type the value you want in it
    In query behind just make filter like below
    WHERE field = CASE WHEN @Param1 <> '<None>' THEN @Param1 ELSE @Param2 END
    Please Mark This As Answer if it helps to solve the issue Visakh ---------------------------- http://visakhm.blogspot.com/ https://www.facebook.com/VmBlogs

  • Dear freinds how to open the fields in the PNP selection screen

    Dear Freinds,
             When you use the PNP selection screen , i dont find the Orgeh field in default selection screen .
    However , using the code at selection screen output i have closed certain feilds using the loop at screen,
    but when iam trying in similar way to show the field
    on the selection what is the code i have to use
    in the loop at screen...........especially for the field
    orgeh .
    i have tried the othere options like required.........this working when iam able to make the date fields mandatory, similary i want to try with the below
    code to get the field Orgeh on the selection as default feild when we execute the report.
    can any one  please modify me the code
      LOOP AT SCREEN.
        IF screen-group4 = '026'   .
          screen-active = 0.
          screen-invisible = 1.
           screen-input = 0.
        ENDIF.
        modify screen.
    endloop.
    what i have to use in the loop at screen for me to get the orgeh field on the selection screen.
    thanks & regards
    madhuri

    Hi Madhuri,
    Unless you dont declare the orgeh field in hr report category you cannot show it on the selection screen nor you can hide it.
    If you do not want to use hr report cateogry.
    What you can do is that declare a parameter or selection screen called p_orgeh type orgeh.
    Here you can do the hiding on conditions.
    Kindly note here that after get pernr you will have to put a check that
    check p0001-orgeh in p_orgeh.
    Because for the fields declared by you automatic filtering does not happen.
    Regards,
    Divya
    Pts valuable.

  • Storage Location field active at GR with103

    Dears,
    how i can make storage Location field active at GR with103

    Hi,
    Use T-Code OMJJ,  select Movement Type 103 and in Change View Movement Type Screen Check Storage field and save.
    Hope this helps,
    Best regards
    Amit Bakshi

  • Date field not updated when select on F4 value on editable ALV Grid

    Can some one look into this to see what was wrong.
    I have a report that display fields extracted from a ZTable and display on an ALV Editable Grid.
    The data are displayed as read only mode for these fields:
    Field A -   type char20 and have a search help available.
    Start Date - type dats
    End Date - type dats.
    Field B
    Field C ...
    When user select to add new record,  Field A, Start Date and End Date must be editable, the rest are read only.
    On field A because there is search help available, I have no problem select data on F4 pull down menu and the data is updated on the grid.
    But on field start date and end date, there is F4 menu and when you pull down, it shows the calendar date.  But when I select the date to change, it acts like nothing happens.  I run the debug mode and found out that in function module 'F4IF_FIELD_VALUE_REQUEST', after you select the date field, I got the return code irc = 8 from line 305 of this FM.
    Here is what I did.
    I build field catalog similar like BCALV_EDIT04  (add table type lvc_t_styl to each extracted record to indicate which field will be  editable.
    In the PBO,  I build field catalog and set style as enable for these fields:
    CALL FUNCTION 'LVC_FIELDCATALOG_MERGE'
        EXPORTING
          i_structure_name = p_struct
        CHANGING
          ct_fieldcat      = p_t_fieldcat.
    LOOP AT p_t_fieldcat INTO ls_fcat.
        CASE   ls_fcat-fieldname.
           when 'Field_A'.
               ls_fcat-ref_table = 'ZTABNAME'.
            ls_fcat-ref_field = 'FIELD_A'.
            ls_fcat-edit = 'X'.
            MODIFY p_t_fieldcat FROM ls_fcat.
       when 'START_DATE' or 'END_DATE'.
        ls_fcat-style = CL_GUI_ALV_GRID=>MC_STYLE_enabled.
             MODIFY p_t_fieldcat FROM ls_fcat.
       endcase.
    Just curious, I copied program BCALV_EDIT_08 to ZBCALV_EDIT08 and make field booking date as editable to test.  When I select to change booking date from F4 menu pull down, the new date is populated to the screen field.  So what was wrong between my program and BCALV_EDIT_08?  Thanks for your help.  I am stuck on this problem for 2 days and could not figure out what was wrong.

    not sure why you use that FM for date filed , you just need in the field catalog make sure that are use a date field of reference , anyway check program BCALV_EDIT_01

  • When I open logic express 8 with eyetv open but not active and i close logic express 8 and make eyetv active it won't show closed captioning even though closed captioning is turned on

    when I open logic express 8 with eyetv open but not active and i close logic express 8 and make eyetv active eyetv won't show closed captioning even though closed captioning is turned on.  When I totally close eyetv and reopen eyetv and open a live tv window the closed captioning comes back.  I never noticed this with os leopard, Just after i installed os snow leopard.  All software is up to date only I think, thanks to apple they droped support for logic express.  Thanks for any suggestions.

    Does toggling CC off & back on bring it back?
    "Try Disk Utility
    1. Insert the Mac OS X Install disc, then restart the computer while holding the C key.
    2. When your computer finishes starting up from the disc, choose Disk Utility from the Installer menu at top of the screen. (In Mac OS X 10.4 or later, you must select your language first.)
    *Important: Do not click Continue in the first screen of the Installer. If you do, you must restart from the disc again to access Disk Utility.*
    3. Click the First Aid tab.
    4. Select your Mac OS X volume.
    5. Click Repair Disk, (not Repair Permissions). Disk Utility checks and repairs the disk."
    http://docs.info.apple.com/article.html?artnum=106214
    Then try a Safe Boot, (holding Shift key down at bootup), run Disk Utility in Applications>Utilities, then highlight your drive, click on Repair Permissions, reboot when it completes.
    (Safe boot may stay on the gray radian for a long time, let it go, it's trying to repair the Hard Drive.)
    If perchance you can't find your install Disc, at least try it from the Safe Boot part onward.

  • How to add a new Field in the Dynamic Selection screen section.

    HI,
    There is a requirement in which I need to add a field in existing program of dynamic selections.
    I need to add a field KNKK-DBRTG (Customer Rating) in dynamic selections screen of some existing report
    which has a dynamic selection screen with other fields like customer account, company code etc. Along with this i need to add Customer rating field also in the selection screen.
    I have used GET KNKK statement to select this in the Dynamic selection screen. But I need to make it appear
    on the screen.
    LDB used is the Customer Database.
    I have added GET KNKK statement after GET KNA1 statement.
    Can any one help me how we can make this rating field appear in the selection screen.
    With the GET statement Credit control area Fields can be selected in the selection screen but I have to permanantly add the field in the selection screen.
    Regards
    Prashant Prabhu

    Hi,
    So you need that this new field have data in old records?
    1.- If you are in BI 7.0 and the logic or data for that New field are in the same Dimension, you can use a Remodeling to fill it. I mean if you want if you want to load from a Master Data from other InfoObject in the same Dim.
    2.- If condition "1" is not yours.
    First add the new field, then create a Backup Cube (both cubes with the new field) and make a full update with all information in the original Cube. The new field willl be empty in both cubes.
    Create an UR from BackUp_Cube to Original_Cube with all direct mapping and create a logic in the Start Routine of the UR (modiying the data_package) you can look for the data in the DSO that you often use to load.
    To do that both cubes have to be Datasources ( right click on Cube-> aditional function-> and I think is "Extract Datasource")
    Hope it helps. Regards, Federico

Maybe you are looking for

  • Can not download HD movie

    When I attempt to download 'Life of Pi' in HD for 14.99 (using iTunes 11.0.2) it will not works as I get the following error: "If you buy the HD verision, you have to transfer it to an HD-Compatible device in order to watch it. Or you can buy the SD

  • Free of cost sale in Manufacturing

    Hi,   We have one manufacturing plant, as when we create the invoice the customer account is debited and the excis etax account are creadited now in case of free of cost sale we required that insted of customer we have a different GL account the tota

  • Manager's port not reachable

    Golden Gate version: 11.2.1.0.3 DB version : 11.2.0.3 Platform : Solaris 10 I am trying to setup Golden Gate on Solaris. I have two solaris 10 Virtual Machines created using Virtual Box. On the source machine , I started the MANAGER process on port 3

  • My aperture 3.0 doesnt show up in the software update

    How can i force my A3 to update - it wont let me download it because it says i need A3 installed --(and it definately IS) and it doesnt show up when using software update either. What file is missing to get this to do it and how do i fix it? - i trie

  • How to Retrieve a List of Business Objects using DI Server?

    In DI Server (and DI-API) I could not find how I can get a list of business objects, for instance ServiceCall objects. and more - say i need the list with a filter on customer code and call status?