How to clear a record of control block

i have one control block with 2 items and the Max. records displayed property is set to 10.I have populated 5 records and now i want to clear one record, but the clear_record statement does not seem to be working. How to clear a record in a control block. Please help me out in this doubt of mine.

You have probably moved focus to another block. You have to go_block and maybe go_record before using clear_block.

Similar Messages

  • How to Save Multiple Records In Data Block

    Hi All,
    I Have Two Blocks --> Control Block,Database Block
    Please Any Idea How to Save Multiple Records In Data Block when User changed Data in Control Block.
    Thanks For Your Help
    Sa

    Now i have to use each record of control block(ctl_blk) as where condition in data base block(dat_blk)and display 10 records from database table.>
    Do you want this coordination to be automatic/synchronized or only when the user clicks a button or something else to signal the coordination? Your answer here will dicate which trigger to put your code in.
    As to the coordination part, as the user selects a record in the Control Block (CB), you will need to take the Key information and modify the Data Block's (DB) "DEFAULT_WHER E" block property. The logical place to put this code is the CB When-New-Record-Instance (WNRI) trigger. You code will look something like the following:
    /* Sample WNRI trigger */
    /* This sample assumes you do not have a default value in the BLOCK WHER E property */
    DECLARE
       v_tmp_dw    VARCHAR2(250);
    BEGIN
       v_tmp_dw := ' DB_Key_Column1 = '||:CONTROL.Key_Column1||' AND DB_Key_Column2 = '||:CONTROL.Key_Column_2;
       Set_Block_Property('DATA_BLOCK', DEFAULT_WHER E, v_tmp_df);
       /* If you want auto coordination to occur, do the following */
       Go_Block('DATA_BLOCK');
       Execute_Query;
       /* Now, return to the Control Block */
       Go_Block('CONTROL_BLOCK');
    END;
    The Control block items are assigned with values in Form level (Key_exeqry).If your CD is populated from a single table, it would be better to create a Master - Detail relationship (as Abdetu) describes.
    Hope this helps,
    Craig B-)
    If someone's response is helpful or correct, please mark it accordingly.

  • How to clear data in Table Control.

    hi! all
    How to clear the data in table control.
    i have a Table control which displays column A data from the previous screen and allows to enter column B and column C and i have a button CLEAR, when i click CLEAR button the Data displaying in table control has to be cleared. how to do it.
    Regards,
    Nagulan

    Hi,
    Loop over the internal table of table control & clear data from table control.
    loop at tctab.
    clear tctab.
    modify tctab.
    endloop.
    Best regards,
    Prashant

  • How to loop through records in a block

    How do I get the count of records in a data block after the EXECUTE_QUERY?
    If I want to manually insert or update records into the table from the datablock how do I loop thru' records in the block.?
    Also for 'WHERE' clause of update statement is there anyway to tie up the rowid to the current row in the form.

    Use get_block_property('block',QUERY_HITS).
    For the second question :
    Set the properties of block to be INSERT_ALLOWED=FALSE,UPDATE_ALLOWED=FALSE, next do:
    go_block('block');
    first_record;
    set a local handler of errors
    loop
    next_record;
    end loop;
    when others then
    catch the error "Record must be inserted first...'
    For the third question set the DML Returning Value = Yes in property palette of the block and access the rowid as
    declare
    rowid_ rowid;
    begin
    rowid_:=:block.rowid;
    end;
    HTH

  • How to loop through records in the block

    Hello,
    I have 2 blocks one emp_control_block and the other one based on the emp. The emp control block basically has some search critieria which is then passed onto the emp block to execute the query. However, I don't want to show any emp block data until the user presses the search button in the control block then I automatically want to make visible the EMP block and also set the width of columns. Right now, in the properties I have not assigned any Canvas to the EMP Block
    Can anyone tell me How do I loop through the block and show the items/columns in a canvas that I have already created. Any example of the code would be really appreciated. Thanks

    Monica,
    I tried your code but I get NO NAVIGABLE ITEMS IN DESTINATION BLOCK error. In the property palette for the items in the EMP block I have assigned Null as Canvas because I want to programatically assign it to the emp_stack_canvas. How do I do that? Also I want to change the item width for each column to say a fixed width of 50.
    Thanks

  • How can I update record in the block that Data Source is PROCEDURE?

    I like use Procedure as the Data Source of block.It's very flexible.
    Usually I do this only query the record,but now I must update record in the block that Data Source is Procedure.
    What next step can I do?Can anyone offer some examples?
    This is example, you goto
    http://www.2shared.com/file/1923834/e0b65fb7/Example.html
    Wait about 30 sec, Click "Save file to your PC: click here",and then you can download it.

    <p>I have written an article about some advanced Forms features.
    Have a look at the 2.3.2 paragraph</p>
    Francois

  • Forms 6.0-- How can I show records in a block in different colours.

    In a multi record block, how can I show few records in one colour and few more in a different colour depending on a condition.

    Use DISPLAY_ITEM.
    This will change the visual attribute of the item in the current(!) record,
    set_item_property changes the attributes of the item in all(!) records.

  • How to clear data from Table-Control

    Hi all,
    I am working on table control. I have some data on the table control.
    When I press the 'Cancel' button, I require that the table-control should be cleared.
    I tried using REFRESH CONTROL TC01 USING SCREEN 1001. But, the data doesn't get cleared.
    Please advise.
    Regards,
    Saurabh Buksh.

    hi
    good
    try this example
    REPORT demo_dynpro_tabcont_loop_at.
    CONTROLS flights TYPE TABLEVIEW USING SCREEN 100.
    DATA: cols LIKE LINE OF flights-cols,
          lines TYPE i.
    DATA: ok_code TYPE sy-ucomm,
          save_ok TYPE sy-ucomm.
    DATA: itab TYPE TABLE OF demo_conn.
          TABLES demo_conn.
    SELECT * FROM spfli INTO CORRESPONDING FIELDS OF TABLE itab.
    LOOP AT flights-cols INTO cols WHERE index GT 2.
      cols-screen-input = '0'.
      MODIFY flights-cols FROM cols INDEX sy-tabix.
    ENDLOOP.
    CALL SCREEN 100.
    MODULE status_0100 OUTPUT.
      SET PF-STATUS 'SCREEN_100'.
      DESCRIBE TABLE itab LINES lines.
      flights-lines = lines.
    ENDMODULE.
    MODULE cancel INPUT.
      LEAVE PROGRAM.
    ENDMODULE.
    MODULE read_table_control INPUT.
      MODIFY itab FROM demo_conn INDEX flights-current_line.
    ENDMODULE.
    MODULE user_command_0100 INPUT.
      save_ok = ok_code.
      CLEAR ok_code.
      CASE save_ok.
        WHEN 'TOGGLE'.
          LOOP AT flights-cols INTO cols WHERE index GT 2.
            IF  cols-screen-input = '0'.
              cols-screen-input = '1'.
            ELSEIF  cols-screen-input = '1'.
              cols-screen-input = '0'.
            ENDIF.
            MODIFY flights-cols FROM cols INDEX sy-tabix.
          ENDLOOP.
        WHEN 'SORT_UP'.
          READ TABLE flights-cols INTO cols WITH KEY selected = 'X'.
          IF sy-subrc = 0.
            SORT itab STABLE BY (cols-screen-name+10) ASCENDING.
            cols-selected = ' '.
            MODIFY flights-cols FROM cols INDEX sy-tabix.
          ENDIF.
        WHEN 'SORT_DOWN'.
          READ TABLE flights-cols INTO cols WITH KEY selected = 'X'.
          IF sy-subrc = 0.
            SORT itab STABLE BY (cols-screen-name+10) DESCENDING.
            cols-selected = ' '.
            MODIFY flights-cols FROM cols INDEX sy-tabix.
          ENDIF.
        WHEN 'DELETE'.
          READ TABLE flights-cols INTO cols
                                  WITH KEY screen-input = '1'.
          IF sy-subrc = 0.
            LOOP AT itab INTO demo_conn WHERE mark = 'X'.
              DELETE itab.
            ENDLOOP.
          ENDIF.
      ENDCASE.
    ENDMODULE.
    thanks
    mrutyun^

  • How to display multiple records in a block text items

    Can fetching be done to dispplay multiple records in the text items base on the query.

    put the code in post-query trigger

  • Clear the records region level

    Hi
    I want to clear records from contril item in particular region when naviagate to another region,
    how to clear the particular region control item( records)?
    thanks
    renga

    Could you try be a bit more clearer about what you want too achieve please? Im thinking that you have 2 regions on a page and when you navigate to another region you want to clear the previous region?

  • How to color the records in a tabular form

    hi,
    i am using oracle 10g forms
    how to change the color of records on conditional basis in a tabular form display.
    thanks

    Well i give u item level to apply it in the whole record including...
    emp , ename & sal
    any way to do it block level u can use Current Record Attribute Property block level but if u programatically do it as mentioned u can have a lock on something resemble to ur case pls have a look at Craig's Oracle Stuff How to Select Multiple Records in a block using Record Groups just to exclude the idea u want to develop.
    Hope this helps...
    Regards,
    Amatu Allah

  • Control Block - Preventing creation of new record

    hi,
    i have a control block with two text fields. i do not want new record created for this block when the down key is pressed.
    How do i do that ?

    Re: data disappears when pressing down arrow key

  • How to clear the contents of table control

    Hi All,
              How to clear the contents that are present in a Table control. If there is any code Please Let me know.
    I will assign full marks to the correct code.
    Pradeep Kumar Kota.

    Hi
    U need to clear the contenents of internal table used to store the record displayed by table control.
    Every time the PBO is triggered the table control is automatically cleared, so you need only not to transfer any data from internal table to table control.
    So you should show how your PBO if you want a right answer.
    Max

  • RM-30410: Warning: Single Record property ignored for non-control block

    Hi gurus,
    I have one block, as oracle default behavious is that when any user enters record and during that if he/she hits down arrow key then it gets to next new record, i want to prevent this behaviour.
    In other words i want that user should not enter second record and if he or she needs to enter second record after saving first then user can only do if he navigate to the form second time.
    In property pallete i put yes to single record but when i compile the form it gives me following warning
    FRM-30410: Warning: Single Record property ignored for non-control block Employees
    Created form file C:\my_forms\employees.fmxPlease seeks help that how can i sort it out.
    Thank you
    Hina

    if he/she hits down arrow key then it gets to next new record, i want to prevent this behaviour. Change the block's key-down and/or key-nxtrec trigger to
    begin
      null;
    end;(or give the user a message "Key not allowed here").

  • Error in ST05 - trace record pair error block. How to resolve/tackle issue?

    Hello,
    Someone approached me last week in asking me how to resolve an issue in ST05. Basically I used the transaction to filter "inclusive VBPA".
    The error is ....
    Internal error - trace record pair error block 8 link no. 0
    Message no. 0S 026
    Diagnosis
        Each SQL statement is described by two SQL trace records that have the
        same link number. In this case, there are at least three records with the
        same link number.
        The system outputs the number of the block in which the third SQL trace
        record was found, as well as the link number of the records.
    System response
        Program processing continues after the message is displayed. The system
        processes all of the trace records. You should assume, however, that the
        SQL trace in this case is not displayed correctly.
    Procedure
    You cannot correct this error yourself. If you can reproduce the error,
    contact the SAP Hotline.
    SQL trace list editing terminated after 6 errors
    While using the trace I am executing the program that selects VBPA once and, I am assuming, as it goes through the BAPI BAPI_SALESORDER_CHANGE used to unblock a delivery block. I am guessing the problem or source is from the BAPI but do you guys have other insights in what is causing this issue?
    Thanks again, hope to hear from you soon, and good day.

    Our ERP LIVE Production around 11am all users encountered cannot generate print record from the submit new request. see below errorFor production issues, please log a SR.
    ORA-00060: Deadlock detected. More info in file /u/oracle/PROD/db/tech_st/11.1.0/admin/PROD_tailindb/diag/rdbms/prod/PROD/trace/PROD_ora_4026.trc.
    ORA-00060: Deadlock detected. More info in file /u/oracle/PROD/db/tech_st/11.1.0/admin/PROD_tailindb/diag/rdbms/prod/PROD/trace/PROD_ora_4026.trc.
    ORA-00060: Deadlock detected. More info in file /u/oracle/PROD/db/tech_st/11.1.0/admin/PROD_tailindb/diag/rdbms/prod/PROD/trace/PROD_ora_4026.trc.Please see these docs.
    OERR: ORA 60 "deadlock detected while waiting for resource" [ID 18251.1]
    What to do with "ORA-60 Deadlock Detected" Errors [ID 62365.1]
    Thanks,
    Hussein

Maybe you are looking for

  • EDI Seeburger problem

    Hey, I'm testing an invoice EDI file which contains 3 invoices. I'm putting the edi file in the ftp but nothing happens. When I check the channel it says this: Error: com.sap.engine.interfaces.messaging.api.exception.MessagingException: MESSAGESPLITT

  • BI under nw7.3

    Hello I would like to install an BI system based on NW7.3 After starting sapinst from..51041560/DATA_UNITS/NW730_IM_HPUX_IA64_ORA I get options.. Application server ABAP Process integration Application server java Standalone engines Additional SAP Sy

  • Asset Value Problem ?

    Dear , All Experts. I have one scenario in which my asset got capitalized through legacy. Asset was uploaded with around 1 lakh rupees. Later on many transactions posted on same asset and it has book value now 21 Lakh which should not be ! Now my use

  • BI 7.0 Vs BW 3.5

    Hi ,   !) In BW 3.5 there is a an option to link the info provider to the custom authorization object( built using the authorization relavent info object say coscenter) so that when we we execute a query built from the infoprovider, it checks for the

  • Help!!! iTunes has stopped working...

    The message I get in Windows is... "A problem cause dthe program to stop working correctly. Windows will close the program and notify you if a solution is available". That has been the repeated message each time I try and start it, since I installed