How to handle default checkbox(row selector)??

Hi,
I have a form where in there is a default checkbox and i have created a button named CANCELLED to cancel the particular row,when ever the end user wants to cancel a particular row he checks the checkbox so that in the back end we have taken a column cancel_flag where this column should be updated to 'Y' for the checked row by end user.
How can we handle this scenerio for the above context??Please any help will be greatly appreciated.
TIA,
By,
Kranthi.

Kranthi,
I assume your check box has static list of values like
STATIC2:Cancelled;YThen write a after submit conditional pl/sql page-process which executes only when we press 'Cancelled' button.
In the page process, write code similar to
IF INSTR (:p1_checkbox, 'Y') != 0 --check box selected then
THEN
--update table
UPDATE tbl_name
SET cancel_flag='Y'
WHERE pk_id=:p1_pk_id;
END IF;where pk_id is primary key for your table. p1_pk_id is page item for primary key and p1_checkbox cancelled check box.
Hope it helps
Cheers,
Hari

Similar Messages

  • How to create a custom row selector

    I am using APEX_ITEM.CHECKBOX in a form. How can I add a row selector checkbox to the heading of the table to select/deselect all of my custom checkboxes? I tried to simply add the build-in row selector function to the report but that just added an additional column of checkboxes. I just need the header row checkbox added.
    This is Apex 3.2.x
    Edited by: user9108091 on Oct 14, 2010 1:32 PM

    Hello,
    >> How can I add a row selector checkbox to the heading of the table to select/deselect all of my custom checkboxes?
    Please check the following. I believe it’s simpler than the hijacking business.
    Re: How to add row selector column attribute to report region?
    Regards,
    Arie.
    ♦ Please remember to mark appropriate posts as correct/helpful. For the long run, it will benefit us all.
    ♦ Author of Oracle Application Express 3.2 – The Essentials and More

  • How do I add a row selector?

    Hi,
    I have a report. Region is of type 'SQL query'.
    How do I add a row selector to this type of report?
    Toon

    Hi,
    on the "Report Attributes" tab of your report region. It's on the right side in the "Task" frame.
    Patrick
    Check out my APEX-blog: http://inside-apex.blogspot.com
    Check out the ApexLib Framework: http://apexlib.sourceforge.net

  • How to handle the dynamic rows in pdf table

    Dear All,
    earlier i posted one thread reagarding getting pdf table data
    [facing problem while getting interactive form table data;
    this is working fine, i sued bind_table in wddoinit, but here i am fixing the rows count and bind_table.
    for example i have initially taken row count as 3 then i want to increase the rows in pdf table.
    i know we can use the formcalc to increase the rows by taking a button in pdf layout.
    this also working, but the data is not picking for newly added rows, i hope the problem is because the table node in the context is not binded for this new rows.
    even i tried using with webdynpro native button controlls still not working.
    any one help me what exactly this bind_table is doing and how to handle this code in form calc.
    since my table is pdf table.
    Thanks,
    Mahesh.Gattu

    Hi Thomas,
    Thanks for your confirmation,
    i have checked the paramets of submit button we have only wdevent parameters they are
    CL_WD_CUSTOM_EVENT
              PARAMETERS - Hashed table having 2 columns
              ID     ->IF_TDS (Interactive Form element Name)
             CONTEXT_ELEMENT     ->->
    these are same in case of submit button1 and submit button 2.
              NAME - Name of the Button Event i.e ON_SUBMIT (  this is also same in both the buttons).
    so i think it is not possible to work with multiple buttons by assinging to multiple tables on form.
    The other option is to place the buttons outside of the forum in the surrounding WDA area.
    This way you have no problem handling the events.
    in wddoinit if i use bind_table with 5 rows form table is populating with 5 rows, but when i take a button
    out side the form and use bind_table by incremeting the rows the pdf table rows are not adding, if i enter
    some thing on pdf table then click on add row button then the table rows are getting add. if i don't do any
    action on pdf table and click on add row button pdf is not getting update.
    is there any issue.. if i don't keep cursor on table and type some thing.. the add button is not updating
    the rows.
    if i take a  button on wd view i.e outside the form and use bind table i shall add the rows.. but in case of remove rows how to do.
    in case of normal table we can use Remove_Element( ) but how can i know the selected row from the pdf table, please help me in this concern also.
    Regards,
    Mahesh.Gattu
    Edited by: Maheshkumar gattu on Jan 7, 2009 3:57 PM
    Edited by: Maheshkumar gattu on Jan 7, 2009 4:03 PM
    Edited by: Maheshkumar gattu on Jan 7, 2009 5:21 PM

  • How to Handle the chaned rows and new added rows into ALV in OPPS alv .

    Hi All,
    I have developed a [program in which i am able to append a row or change and existing row.
    when i press save button and handle the user command in PAI of Screen, in the internal table of ALV some records are missing which are inserted in the last.
    Could You please guide me how can i handle the change rows and appended rows
    Regards,
    Deepak

    Hi ,
    as avinash said , u need to use check_changed_data Method in order to get all records ,
    code will be like this
    PAI
    user-command.
    case sy-ucomm.
    when 'ENTER'.
    call method G_grid->check_changed_data.
    call method g_grid->refresh_table_display.
    when 'SAVE'.
    call method G_grid->check_changed_data.
    call method g_grid->refresh_table_display.

  • How to handle unchecked checkboxes in JSP?

    I have been trying to use <input type=checkbox > tag to handle the checkbox , but it only sends values for checkboxes tht are checked .. if not checked then those checkboxes are not handled, i also came across a code like
    <% String checked = (del.equals("")) ? "" : "checked"; %>
                   <input type=checkbox name=del value="Y" <%=checked %>/>
    but this gives error tht it does not recognise 'del' attribute..
    please send me any solution at [email protected].
    thanks in advance.

    Prakash_Pune wrote:
    tell me some Debugging tech. so i can overcome from my problem.....Do you use an IDE? Any IDE ships with a decent debugger where in you can just execute the code step by step, explore the current variable values and check what exactly is happening. For example Eclipse or IntelliJ. If you don´t use an IDE, then just place some System.out.println() or Logger.debug() statements at strategic locations printing the variables of relevance so that you can track in logs what exactly is happening.
    or tell any other way to find is my page is thread safe or not...Just write correct code and narrow the scope of the variables as much as possible. If you for example assigned the user object to a static variable or as a servlet´s instance variable, then exactly the same user object would be used everywhere in the application. That kind of logical things.

  • How to disable check box (row selector) in a tabular APEX report

    I have a tabular report with check boxes that gets populated by a SQL query.  For certain rows, I want to disable (or not render) the check box, depending on the value of one of the columns for that particular row (if the value of a column defined as Date is less than sysdate, I don't want to display the check box for that row).  I tried using the Conditional Display in the Column Attribute section of the check box, but I am unable to access this Date column which is being selected from a view in the source SQL.  I used variable such as :name-of_column, V(':name-of_column'), but always get a NULL value for this Date column in the SQL that I am trying to code in the Conditional Display section.  For this reason, my condition does not work correctly.
    What am I doing wrong?  Is my approach above correct?

    Hi Ajay,
    I don't think you can handle this with a conditional display, as that works on column level rather than row level.
    The way I see it, there are two things you can do:
    1) an sql approach, where youo render the checkbox as part of your query using apex_item.checkbox, check the oracle docs for detailed info on the usage APEX_ITEM
    You'll end up with a query like
    select case when YOUR_DATE_COLUMN < sysdate
                      then null
                      else  apex_item.checkbox2( p_idx => 1
                                                               , p_value => YOUR_DATE_COLUMN
    ,      <rest of your query here>
    from YOUR_TABLE
    2) an JavaScript approach in which you create a dynamic action that check your tabular form date column and, when necessary hides and disables the checkbox for that row.
    First option is more robust, but will require a bit more work. Second option is faster to develop, but might have different effect across various browsers and browser versions.
    Regads,
    Vincent
    http://vincentdeelen.blogspot.com

  • I'm getting "How to handle Default Aspx file?" whats wrong?

    When I try to log into Hotmail I get this question. "How should Firefox handle the Default Aspx file"
    How do I fix it?
    My operating system is Microsoft Vista
    and Firefox 5 i think.

    Read this article, especially the bit about loadercontext and currentdomain:
    http://blogs.adobe.com/airodynamics/2012/11/09/packaging-and-loading-multiple-swfs-in-air- apps-on-ios/

  • How to handle the current row with radio button selection???

    Hi Everyone,
    I have one ADF page with one table and one "Find" button.
    I have created one new attribute with VARCHAR2(1) in the VO and dragged that attribute as first column in the table. And changed that first column to Radio Button to select only one row at a time.
    Upon clicking on the "Find" button i need to get the values of current selected row.
    How can i get the values of selected row?
    What code should i write to get the values of selected row in Method Binding of "Find" button?
    Any suggestions will be really useful.
    Thanks.

    Hello Kumar,
    I have some comments on your case.
    >
    I have created one new attribute with VARCHAR2(1) in the VO
    >
    1- You should create this attribute in the Entity object and then add it to the view object.
    2- Do you need that only one radio button is set at a time for all rows ? If yes then you need to handle the case when the user set more than one row and clear the value of the attribute for all other rows.
    >
    How can i get all the values of current row in backing bean method(method binding of Find method)?
    can u plz provide me the code for that?
    >
    If you mean by the current row is that the row with its value of the selected attribute is set (the radio button is set for that row), then you can write a method in the viewObjectImpl class and expose it to client interface and call it from your bean.
    here is an example based in Department table in HR schema.
    //This method is written in DepartmentsViewImpl   
    public Row getSelectedRadioRow(){
                //create a second row set to not impact the row set used in ADF
                RowSet duplicateRowSet = this.createRowSet("duplicateRowSet");
                //get the current row of the table to set it back after re-executing the VO
                DepartmentsViewRowImpl currentRow = (DepartmentsViewRowImpl)this.getCurrentRow();
                Row[] filteredRows = duplicateRowSet.getFilteredRows("IsSelected", "1");
                DepartmentsViewRowImpl row=null;
                if(filteredRows.length>0){
                    row = (DepartmentsViewRowImpl)filteredRows[0];
                    System.out.println("Department Name " + row.getDepartmentName());              
                this.setCurrentRow(currentRow);
                duplicateRowSet.closeRowSet();
                return row;           
            }

  • Apex report performance is very poor with apex_item.checkbox row selector.

    Hi,
    I'm working on a report that includes some functionality to be able to select multiple records for further processing.
    The report is based on a view that contains a couple of hundred thousand records.
    When i make a selection from this view in sqlplus , the performance is acceptable but the apex report based on the same view performes very poorly.
    I've noticed that when i omit the apex_item.checkbox from my report query, performance is on par with sqlplus. (factor 10 or so quicker).
    Explain plan appears to be the same with or without checkbox function in the select.
    My query is:
    select apex_item.checkbox(1,tan_id) Select ,
    brt_id
    , tan_id
    , message_id
    , conversation_id
    , action
    , to_acn_code
    , information
    , brt_created
    , tan_created
    from (SELECT brt.id brt_id, -- view query
    MAX (TAN.id) tan_id,
    brt.message_id,
    brt.conversation_id,
    brt.action,
    TAN.to_acn_code,
    TAN.information,
    brt.created brt_created,
    TAN.created tan_created
    FROM (SELECT brt_id, id, to_acn_code, information, created
    FROM xxcjib_transactions
    WHERE tan_type = 'DELIVER' AND status = 'FINISHED') TAN,
    xxcjib_berichten brt
    WHERE brt.id = TAN.brt_id
    GROUP BY brt.id,
    brt.message_id,
    brt.conversation_id,
    brt.action,
    TAN.to_acn_code,
    TAN.information,
    brt.created,
    TAN.created)
    What could be the reason for the poor performance of the apex report?
    And is there another way to select multiple report records without the apex_item.checkbox function?
    I'm using apex 3.2 on oracle 10g database.
    Thanks,
    Niels Ingen Housz
    Edited by: user11986529 on 19-mrt-2010 4:06

    Thanks for your reply.
    Unfortunately changing the pagination doesnt make much of a difference in this case.
    Without the checkbox the query takes 2 seconds.
    With checkbox it takes well over 30 seconds.
    The second report region on this page based on another view seems to perform reasonably well with or without the checkbox.
    It has about the same number of records but with a different view query.
    There are also a couple of filter items in the where clause of the report queries (same for both reports) based on date and acn_code and both reports have a selectlist item displayed in their regions based on a simple lov. These filter items don't seem to be of influence on the performance.
    I have also recreated the report on a seperate page without any other page items or where clause and the same thing occurs.
    With the checkbox its very very slow (more like 20 times slower).
    Without it , the report performs well.
    And another thing, when i run the page with debug on i don't see the actual report query:
    0.08: show report
    0.08: determine column headings
    0.08: activate sort
    0.08: parse query as: APEX_CMA_ONT
    0.09: print column headings
    0.09: rows loop: 30 row(s)
    and then the region is displayed.
    I am using databaselinks in the views b.t.w
    Edited by: user11986529 on 19-mrt-2010 7:11

  • How to handle the Rowalreadydeleted,Row inconsistent exception in adf

    Hi all,
    In my application user can update,delete the database table.
    If one user deletes the row and other user tries to update the same row then i am getting the error and the user how got this error was not able to perform any operation on other rows.
    how can i overcome this scenario.
    Thanks in advance

    may be this will help you
    http://jobinesh.blogspot.com/2010/03/what-you-may-need-to-know-about-nested.html
    and from jobinesh comment's
    If you need locking and want to find the root cause for the RowInconsistentException, then probably the following points may help you
    1.Please check whether your EO has a attributes populated by DB trigger(update/insert).If yes, set the right 'Refresh After' property for this attribute.
    2. Please see this post http://www.avromroyfaderman.com/2008/05/bring-back-the-hobgoblin-dealing-with-rowinconsistentexception/, thttp://www.avromroyfaderman.com/2008/05/bring-back-the-hobgoblin-dealing-with-rowinconsistentexception/
    This link contains some code snippet which can be used to identify the attribute which cause the RowInconsistentException

  • How to handle newly generated rows values?

    Hi all,
              My requirement is to generate rows after output is generated.I am able to generate the rows .But my problem is user can generate multiple empty rows.Suppose he generated 2 empty rows .After generating those 2 empty rows.In the first newly generated row he  will select one value help.My problem is that data_change event is trigerring when that f4 help is populated.After that I select the value from f4 help and goes to the second newly generated row and again does the same thing.Now my requirement is for these 2 lands,I want to pick up all the available tests from the database table for these 2 lands and display in the grid.There may be multiple tests available for each land in the database table.
    I am getting wrong values in the data_changed method.Can I use handle_data_changed_finished event for this.I am not able to catch the absolute values using data_change event.
    Can any one help in this regard?
    Thanks,
    Balaji

    Hi Gaurav,
    Thanks for the replay , here for table switcher how can we differienciate between the message text and lov ,to capture lov values i have searched alot, here is my code.
    In process from request.
    OAApplicationModule am = (OAApplicationModule)pageContext.getApplicationModule(oawebbean);
         OATableBean tb = (OATableBean)oawebbean.findIndexedChildRecursive("EamRetMaterialToInvDetail");
         OASwitcherBean SwitcherRN=(OASwitcherBean)oawebbean.findChildRecursive("EamMaterial");
         if(SwitcherRN!=null)
    // id EamAddNewMaterial
    if (pageContext.getParameter("EamAddNewMaterial")!=null)
    if(pageContext.isLovEvent())
    if("lovValidate".equals(pageContext.getParameter(OAWebBeanConstants.EVENT_PARAM)) || "lovUpdate".equals(pageContext.getParameter(OAWebBeanConstants.EVENT_PARAM))||"lovPrepare".equals(pageContext.getParameter(OAWebBeanConstants.EVENT_PARAM)))
    String lovInputSourceId = (String)pageContext.getLovInputSourceId();
    if("EamMaterialName".equals(lovInputSourceId))
    /*String workorderID = null;
    String lovInput = (String) lovBean.getValue(pageContext);
    OAMessageLovInputBean lovBean=(OAMessageLovInputBean)oawebbean.findChildRecursive("EamMaterialName"); */
    // pageContext.writeDiagnostics(this,"After : "+pageContext.getParameter("EamAddNewMaterial"),4);
    pageContext.writeDiagnostics(this, "Vamsi: LOV caught", 4);
    Can you please sugget me

  • How to handle dynamically created row values when get upadted "please help"

    Hi,
    In my application I have requirement to display the data for specific date when user clicks on viewData. (it shows the entries for that specific days . There may be number of entries). For showing this I have created Value Object and I am setting all the entries for particular selection date to value object and (simply one day entry indicates one instance of my VO if there are 10 entries then I am creating 10 instances of VO and passing this to the actionfor)
    On my JSP page I am displaying that data by using <logic:iterate>
    <logic:iterate id=�myid� name =�nameofform� property =�Listproperty�>
    <tr>
    <td><input type=�text� property=�abc� value=<bean:write name=�myid� property=�propertyinVO�></td>
    // and same for other other values as well
    �.
    </logic:itearte>
    Now I have requirement that if user edit these entries and click on SAVEDATA the updated values should go to the DB.
    As I don�t have property mapped separately I am not able to take updated values of those as they are getting dynamically generated
    Is there is any way by which I can get these updated values.
    I am in badly need of that . Urgent help will highly appreciated.
    Thanks
    Sheena

    Hi, first off, no need to determine what has been checked or not. If the checkbox is checked, on the post, the value will be submitted as part of the request. If the checkbox is not checked, it will not be submitted (it's value will be null). Depending on what you need, I have approached this a number of different ways. One way is to name all checkboxes the same name. If you need to distinguish between two rows in the form, then in the value field for the checkbox, use some type of distinguishing factor, for example,
    <input type=checkbox name=chkName value="1:abc">
    <input type=checkbox name=chkName value="1:def">
    Now, you only have to make one call on the Servlet/JSP receiving the form post, request.getParameterValues("chkName") which will return an array of the non-null Strings that were checked.

  • How to handle radio /checkbox options

    If you have a report like so
    select HTMLDB_ITEM.RADIOGROUP(1,accid,'keep') "Accept",HTMLDB_ITEM.RADIOGROUP(1,accid,'delete') "Delete" ,accid,userid,username,authfails,clientid,tncdate,docsource,lastlogin,usertype,dateadded,recert from GFMIS.AUTOBAHNDIRECTACCOUNTS where recert = '0'
    Which would diplay two radio buttons one with keep and one with delete. When run run this through a process like
    FOR i in 1..HTMLDB_APPLICATION.G_F01.COUNT LOOP
    UPDATE GFMIS.AUTOBAHNDIRECTACCOUNTS SET recert = '1', RECERTBY = :APP_USER, RECERT_DATE = SYSDATE, RECERT_ACTION = 'radiobutton' WHERE ACCID = HTMLDB_APPLICATION.G_F01(i);
    END LOOP;
    How do i say if radiobutton = 'keep then RECERT_ACTION = 'what ever radio button was selected'

    Hi Kiranmai,
    You can capture the event of the radio button in the following way in oninputprocessing.
    DATA: event             TYPE REF TO if_htmlb_data,
                   radioButton_event TYPE REF TO CL_HTMLB_EVENT_RADIOBUTTON.
             event = cl_htmlb_manager=>get_event( request ).
             IF event IS NOT INITIAL AND event->event_name = htmlb_events=>radiobutton.
               radioButton_event ?= event.
               ENDIF.
    you can get the attributes of clicked radio button in
    event->event_class
    event->event_id.
    event->event_name
    event->event_type
    event->event_server_name
    In layout define the radio button as
    <htmlb:radioButtonGroup   id          = "test_id">
            <htmlb:radioButton      id          = "id_red"   text = "Red"               onClick="myClick" />
            <htmlb:radioButton      id          = "id_blue"  text = "Blue"          onClientClick="alert('blue clicked')"/>
            <htmlb:radioButton      id          = "id_green" text = "Green"      onClick="myClick" onClientClick="alert('green clicked')"/>
          </htmlb:radioButtonGroup>
    Hope this will solve your problem.
    Donot forget to assign points for helpful answers.
    Regards
    Aashish Garg

  • How to add a row-selector to an existing SQL Query (updatable report)

    Hi,
    I screwed up an extensive updatable report in Apex 4.2 region by one time indicating the page may be parsed at run time.
    After setting this back (to validate query) a lot of the columns setting were gone, and also the row-selector
    I actually don't kno how to simply add this row-selector back into place.
    Anyone who can point me in the right direction?
    Thanks a lot
    Wim

    Wim,
    >
    Hi,
    I screwed up an extensive updatable report in Apex 4.2 region by one time indicating the page may be parsed at run time.
    After setting this back (to validate query) a lot of the columns setting were gone, and also the row-selector
    I actually don't kno how to simply add this row-selector back into place.
    Anyone who can point me in the right direction?Have you been able to recover all your other configuration and this is the last thing you need to fix? Or are all those other things needing to be fixed as well?
    The reason I ask is that you may want to consider just starting from scratch, if you haven't put lots of effort into recovering everything else just yet.
    On the other hand, if you just want to add a checkbox back into the SQL statement then you can add this, substituting your column name for empno of course:
    APEX_ITEM.CHECKBOX2(1,empno,'CHECKED') "Select"When you do this you'll get a warning that you're changing the interactive report, which you should accept. Then you need to make sure that the column is actually shown in the interactive report by making sure it's in the displayed columns list. And you may also need to change the display type of the column to "Standard Report Column"
    Hope that helps.
    Earl

Maybe you are looking for