How to save Checkbox inputs as a Variants in WD ABAP

Hi,
I am going through this nice blog [http://www.sdn.sap.com/irj/scn/weblogs;jsessionid=(J2EE3414700)ID0832150950DB20043138143752756391End?blog=/pub/wlg/10731] which helped me creating varaint options for SELECT -optins fields.
Everything works fine..
Now I want to save some selection screen Check boxes , plus input fields in to this.
I have NODE called ATTR in which I have checkboxes attributes like ATT1,ATT2,ATT3 etc..
So what I was trying to pass the checkbox values by reading and then  assigning it to lv_att1 but it says i cannot change value..
where am i going wrong?
method HANDLEFROM_SAVEVARIANT .
  DATA lo_nd_attr TYPE REF TO if_wd_context_node.
  DATA lo_el_attr TYPE REF TO if_wd_context_element.
  DATA ls_attr TYPE wd_this->element_attr.
  DATA lv_att1 LIKE ls_attr-att1.
** navigate from <CONTEXT> to <ATTR> via lead selection
  lo_nd_attr = wd_context->get_child_node( name = wd_this->wdctx_attr ).
* get element via lead selection
  lo_el_attr = lo_nd_attr->get_element(  ).
* get single attribute
  lo_el_attr->get_attribute(
    EXPORTING
      name =  `ATT1`
    IMPORTING
      value = lv_att1 ).
wd_this->lt_att1  = lv_att1.
wd_this->lt_range_table = lt_range_table .
  wd_this->M_HANDLER->SET_RANGE_TABLE_OF_SEL_FIELD(
             exporting I_ID = 'PS_PSPID'
                       IT_RANGE_TABLE = lt_range_table  ).
I

Hi iam a starter in ABAP and i got a small error while coding that is
PARAMETERS:
  ABAP  AS CHECKBOX.
  SELECTION-SCREEN COMMENT 5(4) text-010.
  SELECTION-SCREEN END OF LINE.
  SELECTION-SCREEN BEGIN OF LINE.
  PARAMETERS:
  MM AS CHECKBOX.
  SELECTION-SCREEN COMMENT 5(4) text-011.
  SELECTION-SCREEN END OF LINE.
  selection-screen end of block nam1.
if ABAP = 'X'.
WRITE ' YOU ARE ELIGIBLE CONSULTANT'.
ENDIF.
in the above code my requirement is when i check the abap the following msg must be showed in the output screen but its not showing..
please help me if anyone knows how to do it. thank you.
And this is the part of the code if anyone want to see whole code it is attached with this thread.

Similar Messages

  • How to save User input into DB using webdynpro abap

    Hi,
    Im trying to create an application using webdynpro abap.
    I want to know how to save the data input by user, into a database table.
    In my UI, I have a table control which is editable and user inputs data into this. I need to know how i can transfer this data to a DB table.

    hello,
    u can do it by reading ur context node.
    we bind our UI elements to context attributes of appropriate type .
    we read their values using the code wizard or by pressing control+F7, click on radio button read node/attribute
    here for ur specific case , u must have binded ur table control with the context attribute , now u need to simply read this attribute
    eg suppose u have created a context node " cn_table"
      reading context node cn_table
       DATA : lo_nd_cn_table TYPE REF TO if_wd_context_node ,
             lo_el_cn_table TYPE REF TO if_wd_context_element ,
             ls_cn_table    TYPE wd_this->element_cn_table.
    *   navigate from <CONTEXT> to <CN_TABLE> via lead selection
      lo_nd_cn_table = wd_context->get_child_node(
                       name = wd_this->wdctx_cn_table ).
    **    get element via lead selection
      lo_el_cn_table = lo_nd_cn_table->get_lead_selection(  ).
      lo_el_cn_table->get_static_attributes( IMPORTING
                 static_attributes = wa_table ).
    here wa_table is the work area of structure type . u need to create a structure first with the same variables as there are the context attributes in ur node cn_table
    in ur
    now ur wa_tablecontains value
    u can nw use appropriate FM to update , delete and modify the DB table using the value
    u cn directly use SQL statements as well in the method of ur view , but direct SQL statements are nt recommende
    rgds,
    amit

  • Hi everybody how to save the inputed data in one simple list output .

    here am wrting the description of the requirement ...
    am displaying one report output in that output i have all my fields open so that user can directly chage the dats what ever needed or he needs.
    then after changing when he will press the save button the changed data should be saved to one of the database tables ..
    so can anybody please help me out how to do this requirement
    this is a simple report with all fields in the output screen in input mode

    hiiii
    if you want to save the data that user have updated then use following statement on SAVE button.
    UPDATE ztable1
    SET    C1 = 2   
    WHERE  C2 IN ( SELECT C3
                   FROM   T2
                   WHERE  C4 = 0)
    reward if useful
    thx
    twinkal

  • Save an input mask as variant for a method of a Z class

    Hi all,
    quite a dumb question, but I switched to OO abap recently and can't find this feature...
    When I'm creating a custom function module, I can test in debug simply lauching it and saving parameters of the input mask iin a Variant, so that I can try the run with these params whenever I want simply loading the variant I saved.
    Now... I'm working on a method in a custom class; I'd like to test but everytime I have to populate the parameter mask since I can't find a "save variant" option. Is there any way to accomplish this? Thanks in advance.

    Could write an ABAP UNIT class and definition and perform ABAP UNIT test on the object...ABAP Unit is regression testing for programmers but I do development testing with the tool.

  • How to save user input data in pages into database ?

    Dear Friends,
    Hello. I am developing my first PeopleSoft application using PeopleTools 8.49 and SQL Sever 2005. In application designer, I have created fields, records, records' underlying tables in database, and pages. After users type in data into fields in a page, we need to click "submit" button in the page and save the data into Database. How to submit data into database ?
    If we use JBuilder or Netbean instead of PeopleTools, we simply develope a server side script file like sth.jsp and link it to the "submit" button. The server side script file save data into Database. But in PeopleSoft application designer, I don't understand how to submit data in a page into database.
    Can any friends help to solve this question ? Thanks.
    Lucy

    Hi:
    Data will be saved in the database once you click on the 'Save' button on the page or if you use one of the 'Save' functions in PeopleCode (like DoSave(), DoSaveNow()). Generally, there is no need to write a script explicitly. Please refer to PeopleSoft Internet Architechture and PeopleCode peoplebooks (and other PeopleTools peoplebooks as well) for more reference.
    You may want to attend PeopleTools training if you are fresh to PeopleSoft development.
    Regards,
    Sameer.

  • How can do bach input in test client ? where ABAP not possible.

    "Changes to Repository or cross-client Customizing are
    not permitted"
    Can any buddy tel me  how can I register bulk of data from excel file ,to AS01 transaction code ?
    Client is test client where i want to register dada while going by recording method of BDC got error 
    "Changes to Repository or cross-client Customizing are
    not permitted"
    Can any budy tel me alternative option how can i register it ?
    is LSMW OK in this case?

    Hi,
    If this is one time load, then LSMW is suggestible.
    LSMW in turn can use BAPI/IDOC/BDC methods. Since you told the using BDC you dont have authorization.
    Check LSMW with BAPI method and use the BAPI for AS01: BAPI_FIXEDASSET_CREATE1
    Hope this helps
    Regards
    Shiva

  • Save the input data of single WD4A screen

    Hi All,
    I am interested to know, whether as in the case of the ABAP report screen where we can save the input data as variant, is it possible for us to save all the input fields into a variant in WD4A.
    Thanks,
    Selvakumar M.,

    hi,
    Refer the following blogs on Variant in Wd Abap :
    /people/sharad.agrawal/blog/2008/08/21/creating-and-using-variant-in-select-options-with-web-dynpro-for-abap-1
    /people/sharad.agrawal/blog/2008/08/25/creating-and-using-variant-in-select-options-with-web-dynpro-for-abap-2
    I hope it will help you.
    Thanx.
    Saurav.

  • How to save a variant with dynamic selections parameters

    Anybody knows how to save a variant for an ABAP that uses a Logical database with Dynamic Selections?
    Have a look for example to the following:
    SE38 - DEMO_PROGRAM_GET - Execute - Shift F4 - Connection Number.
    How to save 0820 as Connection Number?
    Function Group SVAR seems good but FREE SELECTIONs are not easy to manage...

    Hello,
      I tried to save the variant of DEMO_PROGRAM_GET with dynamic selection field (Connection Number) filled. It gets saved without any problem. Just click 'SAVE' and enter the variant name and description.
    Thanks,
    Venu

  • How to read the input FORMAT of a Checkbox in list.

    hi,
    suppose i have,
    WRITE CHK1 AS CHECKBOX INPUT OFF.
    Now i have, grayed check box,
    Problem. how to read from program, whether the checkbox is input off or on.
    pls reply

    Hi,
    Check this example of how to use the Checkbox in a list..
    REPORT ztest NO STANDARD PAGE HEADING.
    DATA: BEGIN OF itab OCCURS 0,
                check,
                value(20),
              END OF itab.
    SET PF-STATUS 'TEST1'.
    itab-value = 'ETSAT'.
    APPEND itab.
    itab-value = 'ETSATADSF'.
    APPEND itab.
    itab-value = 'ETSAT'.
    APPEND itab.
    LOOP AT itab.
      WRITE: / itab-check AS CHECKBOX,
                    itab-value.
    ENDLOOP.
    AT USER-COMMAND.
      DATA: wa LIKE itab.
      DATA: itab_download LIKE itab OCCURS 0 WITH HEADER LINE.
      IF sy-ucomm = 'DOWNLOAD'.
        DESCRIBE TABLE itab.
        DO sy-tfill TIMES.
          READ LINE sy-index FIELD VALUE itab-check.
          IF sy-subrc <> 0.
            EXIT.
          ENDIF.
          CHECK itab-check = 'X'.
          itab_download-value = itab-value.
          APPEND itab_download.
        ENDDO.
       download
        call function 'WS_DOWNLOAD'
             exporting
                  filename = 'C:\TEST.XLS '
             tables
                  data_tab = itab_download.
      ENDIF.
    Thanks,
    Naren

  • How to save a variant?

    how can i save a variant using abap codes?
    james

    Hi,
    for saving variants to the selection screen,
    1. Enter the values in the selection screen.
    2. Click on the button GOTO.
    3. Goto VARIANTS and click SAVE AS VARIANTS.
    4. Write the name of variant and the meaning. It may be whatever u want to write.
    5. Click the SAVE button.
    6. Variant is created.
    You can see the sign near the execution butoon on selection screen.
    Reward points if helpful.
    thanks

  • How to save a string input by the user to a file

    Hi,
    Can anyone please teach me how to save a string or several string that requires the input of the user into a text file?
    Your help is very much appreciated!
    Thank you!

    http://java.sun.com/docs/books/tutorial/essential/io/index.html

  • How to save input and output in file

    hi ni
    i have program that has some input and some output
    i try to save the input and output in file word office or excel like this
    error
    extended
    ideal
    value
    wq
    wp
    value
    xq
    xp
    0.857143
    0.7
    0.6
    2
    0.5
    1
    1
    thank in advace 
    best regards
    m.s
    lab view  2011
    hi ?Q>
    Solved!
    Go to Solution.
    Attachments:
    adder in exteded stochastic.vi ‏37 KB

    johnsold wrote:
    Read from and Write to Spreadsheet File VIs should do what you want.
    I did not take the time to try to decipher what your program is doing, but I think you could replace all those feedback nodes and Build Arrays with an integer data type and the Rotate function from the Numeric >> Data Manipulation palette.  You will still need one shift regsiter or rfeedback node for each of the four signals.
    You have duplicated code: Divide by 65535, multiply by 2, and subtact 1 followed by a > comparison.  Make that a subVI and place 4 instances on your block diagram.
    Those simple changes will make you diagram understandable, reduce its size to the size of a postcard, and make any future changes easier.
    Lynn
    thank
    hi ?Q>

  • How to call a transaction with a variant

    Hi all
    I created a bdc program after updating it should call another transaction with predefined variant that that transaction program is of type module pool.
    can anyone tell me the syntax how to call a transaction with a variant.

    Hi
    goto Tcode SHD0
    enter the Tcode for which Tran Variant has to be created(dialog Tcode)
    enter Trans variant to be created
    press create button
    it will go through all the screens of that Tcode and save
    and modify the fields as per requirement
    we can create Transaction Variants Using SHD0 Transaction.
    Transaction Variants and Screen Variants
    Transaction variants can simplify transaction runs as they allow you to:
    Preassign values to fields
    Hide and change the 'ready for input' status of fields
    Hide and change table control column attributes
    Hide menu functions
    Hide entire screens
    In particular, hiding fields in connection with screen compression, and hiding screens, can result in greater clarity and simplicity.
    Transaction variants are made up of a sequence of screen variants. The field values and field attributes for the individual screens found in transaction variants are stored in screen variants. Each of these variants is assigned to a specific transaction, can, however, also contain values for screens in other transactions if this is required by transaction flow. The transaction that the variant is assigned to serves as initial transaction when the variant is called.
    There are both client-specific and cross-client transaction variants. All screen variants are cross-client, but may be assigned to a client-specific transaction variant.
    A namespace exists for cross-client transaction variants and screen variants and both are automatically attached to the Transport Organizer. Client-specific transaction variants must be transported manually.
    In principle, transaction and screen variants can be created for all dialog and reporting transactions. There are, however, certain Restrictions that apply to certain transactions, depending on their internal structure.
    No transaction variants are possible with transactions already containing preset parameters (parameter transactions and variant transactions).
    Regards
    Anji

  • How to Enter multiple inputs at a time in Form or Table

    Hi,
    I have one doubt in Webdynpro with java. How to enter multiple inputs at a time?
    For Exam My requirement is we will take employee details node under node empid, name, sal  etc some attributes is here
    Client asking like this enter multiple inputs at a time that data will saved in ECC System.
    1.     By using form how can enter enter multiple inputs at a time I donu2019t this so I will take table(here I will select input fileds). If any possible in form also tell me how I can enter multiple inputs at a time.
    In table suppose 6 rows available So He will enter
                             empid, name, sal  ,firstname, last Name
                             empid, name, sal  ,firstname, last Name
                             empid, name, sal  ,firstname, last Name 
    Like 6 time Click Submit. That data will save in ECC.
    So I was taken table. But in that Table only first row will be editable. I want all 6 will editable that time he will put data in rows then click on submit.
    How to editable these remaining rows? if u have any documents pls send me.
    Regards
    Vijay Kalluri

    Dear Vijay,
    To enter multiple inputs in a table and to make the other rows editable you have to provide that node with initial values.
    by initial values I mean you have to make that much space in your table node.
    For example the name of Node is  yourNode & you have empid, name, sal ,firstname, last Name
    attributes in that node, and you have to make 6 rows editable.
    Then, simply write this code in you wdDoinit() method of your view controller.
    IPrivateYourView.IYourNodeElement e ;
    for(int i = 0 ; i < 6 ; i++ )
    e = wdContext.nodeYourNode().createYourNodeElement();
    e.setAttributeValue("empid" , "") ;
    e.setAttributeValue("name" , "") ;
    e.setAttributeValue("sal" ,  "") ;
    e.setAttributeValue("firstname" , "") ;
    e.setAttributeValue("lastname" , "") ;
      wdContext.nodeOverTimeEnty().addElement(e) ;
    Change YourView with your view name & YourNode with your node name.
    If you have any problem in doing this you can revert back.
    Hope it helps!!
    Warm Regards
    Upendra Agrawal

  • How to save more than one Contact Person in CRM

    Hi experts,
                     How to save more than one contact persons in CRM opportunity Application?
    I am using following Function Module...
      CALL FUNCTION 'CRM_ORDER_MAINTAIN'
        EXPORTING
          it_partner        = lt_partner_com
        CHANGING
          ct_input_fields   = lt_input_fields
        EXCEPTIONS
          error_occurred    = 1
          document_locked   = 2
          no_change_allowed = 3
          no_authority      = 4
          OTHERS            = 5.
    I am giving the input field name as 'PARTNER_FCT', 'PARTNER_NO', 'DISPLAY_TYPE', 'NO_TYPE', 'MAIN_PARTNER' and 'RELATION_PARTNER'.
    The problem is it is saving only one contact person, not more than one.
    Please help me how to save more than one contact persons.

    In SPRO partner processing this needs to be configured.

Maybe you are looking for

  • ITunes 9.0.1 wants me to install IPhone Utility?

    Hi since I installed ITunes 9.0.1, everyday the Apple software update runs and wants me to install an IPhone Utility. I don't have an IPhone and don't want that software on my computer. I click quit each day, is there a way to tell the Apple Software

  • Cust Exit variable- refresh option is not working

    Hi Experts, My requirement is: I am passing a value from manual i/p variable to cust exit variable based on certain condition. The functionality is working fine. But when I changed the value of my manual i/p variable using change variable value optio

  • Ale audit steps

    Hi, Can anybody please explain ale audit steps. 1. i am sending idocs from send1 rece1. how i can i know the status of outbound idocs using ale audit i want to know the process behinds this.

  • Preview clips blacked out in imovie/desktop prefs after 10.4 upgrade

    I recently upgraded to tiger 10.4 and when i open sys prefs/desktop/iphoto folder all of my images come up black squares. The same thing happens when I open imovie and want to access photo clips. The file names appear but images are blacked out. Any

  • REP-58105

    Hello everybody. Im working in RedHat Linux ES/AS 4. with Forms & Reports StandAlone Services. in Developer Enviroment, not in OAS Enviroment. My Problem is when I try run Reports from Forms with run_report_object I have the next message FRM-41213 ca