How to get action to checkbox

hi,
Can somebody help me to get action to checkbox. As im a beginner in JSP, i finds difficulty in getting the right one.

action to checkbox? don't think i've ever heard of anyone doing that before. Sounds like the OP needs something but didn't explain the problem well. But if you really do want to call an action when the user clicks a checkbox (sounds like a bad idea to me but whatever) then yeah, you can use JavaScript

Similar Messages

  • How to get Actions name

    I want to get Actions name by javascript.
    Can get Actions name at javascript?

    Here is an example of creating a list of all the action sets/names to the desktop.
    #target photoshop
    var actionList = getActionSets();
    var outFile = File("~/desktop/Action List.txt");
    outFile.open("w");
    for(var a in actionList){
       outFile.writeln("Action Set " + actionList[a]);
       var aList = getActions(actionList[a]);
       for(var z in aList) {
          outFile.writeln(aList[z]);
    outFile.close();
    outFile.execute();
    function getActionSets() {
    cTID = function(s) { return app.charIDToTypeID(s); };
    sTID = function(s) { return app.stringIDToTypeID(s); };
      var i = 1;
      var sets = []; 
      while (true) {
        var ref = new ActionReference();
        ref.putIndex(cTID("ASet"), i);
        var desc;
        var lvl = $.level;
        $.level = 0;
        try {
          desc = executeActionGet(ref);
        } catch (e) {
          break;    // all done
        } finally {
          $.level = lvl;
        if (desc.hasKey(cTID("Nm  "))) {
          var set = {};
          set.index = i;
          set.name = desc.getString(cTID("Nm  "));
          set.toString = function() { return this.name; };
          set.count = desc.getInteger(cTID("NmbC"));
          set.actions = [];
          for (var j = 1; j <= set.count; j++) {
            var ref = new ActionReference();
            ref.putIndex(cTID('Actn'), j);
            ref.putIndex(cTID('ASet'), set.index);
            var adesc = executeActionGet(ref);
            var actName = adesc.getString(cTID('Nm  '));
            set.actions.push(actName);
          sets.push(set);
        i++;
      return sets;
    function getActions(aset) {
    cTID = function(s) { return app.charIDToTypeID(s); };
    sTID = function(s) { return app.stringIDToTypeID(s); };
      var i = 1;
      var names = [];
      if (!aset) {
        throw "Action set must be specified";
      while (true) {
        var ref = new ActionReference();
        ref.putIndex(cTID("ASet"), i);
        var desc;
        try {
          desc = executeActionGet(ref);
        } catch (e) {
          break;    // all done
        if (desc.hasKey(cTID("Nm  "))) {
          var name = desc.getString(cTID("Nm  "));
          if (name == aset) {
            var count = desc.getInteger(cTID("NmbC"));
            var names = [];
            for (var j = 1; j <= count; j++) {
              var ref = new ActionReference();
              ref.putIndex(cTID('Actn'), j);
              ref.putIndex(cTID('ASet'), i);
              var adesc = executeActionGet(ref);
              var actName = adesc.getString(cTID('Nm  '));
              names.push(actName);
            break;
        i++;
      return names;

  • How to get values against checkbox from table

    hi all,
    how can i get column values from database against multiple check boxes,
    is there array in oracle to store multiple values?
    i stored value of check boxes in column named checkid, in table named information.
    now i want to get value of infoid against these chekid column where checkid=1 from this table and want to store infoid against it in another table named handing,
    i want to do like this
    -----Table handing-------
    HID value1 value2
    1 abc xyz
    1 abc xyz
    1 abc xyz
    2 ccc ddd
    3 bbb aaa
    3 bbb aaa
    i wrote code
         DECLARE
         var_id number;
    CURSOR my_cur is
    select infoid from information
    where CHECKID = 1;
         BEGIN
         open my_cur;
         fetch my_cur into var_id;
         CLOSE my_CUR;
         insert into handing
              (hID,
              value1,
              value2)
         values
              (var_id,
              :handing.value1,
              :handing.value2);
    COMMIT;
         SAVED_ALERT;
    end;
    but i know that var_id data type is number it must be array, this codd does not works what should i do? should i use loop but how??? please help me.
    regars

    Hello Wreesha,
    you can enhance your chance to get an answer in several ways.
    - Use {noformat}{noformat} Tags around your code examples to make them more readable and to preserve white space
    - Provide CREATE and INSERTS for sample data (We still don't know how your information table looks like and what date it has)
    - The expected result (also formatted)
    - Don't use words like "immediate" or "asap". We don't get paid for answering questions.
    Regards
    Marcus                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                           

  • One question for struts2 -How to get action

    My jsp fold structure:Webcontent-index.html
    login -login.jsp
    me-me.jsp
    my java fold : src-login-Login.java
    me-QuestionSubmit.java
    First I login successfully,and go to me.jsp page.By now, every action is work ing.when I submit a form in me page,my jsp code:<form name="frmQuestion" method="post" action="SubmitQues">,but I get 404 error message, HTTP Status 404 - /friends/SubmitQues.
    my struts.xml is follwing:
    <?xml version="1.0" encoding="UTF-8" ?>
    <!DOCTYPE struts PUBLIC
    "-//Apache Software Foundation//DTD Struts Configuration 2.0//EN"
    "http://struts.apache.org/dtds/struts-2.0.dtd">
    <struts>
    <constant name="struts.enable.DynamicMethodInvocation" value="false" />
    <constant name="struts.devMode" value="false" />
    <include file="struts-default.xml" />
    <package name="login" namespace="/" extends="struts-default">
    <action name="ShowLogin" >
    <result>login/login.jsp</result>
    </action>
         <action name="doLogin" class="login.Login">
         <result name="input">/login/login.jsp</result>
         <result name="error">/login/login.jsp</result>
         <result name="success">/me/me.jsp</result>
         </action>
         <action name="SubmitQues" class="me.QuestionSubmit">
         <result name="input">/me/me.jsp</result>
         <result name="error">/me/me.jsp</result>
         <result name="success">/me/me.jsp</result>
         </action>
    </package>
    </struts>
    Thanks first
    Lily

    give the complete error trace............ and here
    <form name="frmQuestion" method="post" action="SubmitQues">your action should carry some post fix right... SubmitQues.do i think.. check your web.xml

  • How to get the  Checked box which are clicked

    for(int k=0;.....
    jsp code
    <input type=checkbox name=checkbox value='<%=k%>' >
    how to get the particular Checkbox which are checked???

    String[] checkedValues = request.getParameterValues("checkbox");You'll get an array filled with the values only for the checked boxes. In other words, if no boxes are checked, checkedValues will be null or checkedValues.length == 0, not sure, going from memory.
    Hope this helps!
    Patrick

  • How to get the value of a checkbox in the backing bean

    How to get the valaue of a checkbox in the backing bean?

    Hi this may help you for selecting single check box
    <h:outputText value="Enabled : "/>
                              <h:selectBooleanCheckbox value="#{Bean.isEnabled}"/>                    
                              <h:commandButton value="Submit" action="#{Bean.submit}"/>
    private Boolean isEnabled;
        public Boolean getIsEnabled() {
            return isEnabled;
        public void setIsEnabled(Boolean isEnabled) {
            this.isEnabled = isEnabled;
        public String submit(){
         System.out.println(isEnabled);
            return isEnabled;
        }for selecting multiple check box
                              <h:selectManyCheckbox value="#{Bean.items}">
                                  <f:selectItem itemLabel="one" itemValue="one" />
                                  <f:selectItem itemLabel="two" itemValue="two" />
                                  <f:selectItem itemLabel="three" itemValue="three" />
                               </h:selectManyCheckbox>
                   <h:commandButton value="Submit" action="#{Bean.submit}"/>
    private List<String> items;
        public List<String> getItems() {
            return items;
        public void setItems(List<String> items) {
            this.items = items;
        public String submit(){
            System.out.println("List : " + this.items);
            return "done";
        }Hope this helps you

  • How to get Checkbox Value from Flex in PHP.

    Hi,
    I need to know how to get a checkbox value from flex in PHP-POST/GET because I don't know what is the value property of a checkbox in flex.
    Please Help.

    Hi,
    It is very simple. Follow the steps below to achieve the solution,
    1. Write a check-box change event to capture the value of the check box. Store this value in a variable(say bolChkSelected:Boolean).
    2. In step 1 you got the value of the check box. Now your aim is to send the value to php. Declare a httpService in your flex application(i think you are aware of using it).Ok..im writing it
    <mx:HTTPService id="sampleService" resultFormat='e4x' url='http://yourdomain/file.php' result='handleResult()' fault='handleFault()'>
    </mx:HTTPService>
    3. Now the actual solution... u need to send the shcStatus in to php..
    Declare an object to hold the data
    var objparameters:Object={};
    objparameters['CheckBoxdata'] = bolChkSelected;
    --in the above line... 'CheckBoxdata' is used as a parameter to php..you shud have the same variable name while accessing in php file also..
    in php file..
    checkboxstatus = $_POST[''CheckBoxdata''];
    echo checkboxstatus
    thats it..

  • How to get an advanced action to respond to text selection in dropdown widgets

    I want to provide a user with a set of dropdowns containing text strings, and if they select the right combination of dropdown entries, give them a Continue button, and if they don't select the right combination then give them an error message and solution.
    The trouble I'm having is I don't understand how to get the action to read the widget selections. I'll go through a demo to show you what I'm doing so far.
    (Context: CP5, and JavaScript/programming ignoramus.)
    Objects in the demo
    My steps so far
    1. Set up two user variables
    2. Create two dropdown widgets (Widget1 and Widget2) each with labels "Right" and "Wrong" and point them to the two variables.
    3. Add a Continue button and a text box labelled Wrong, each set to invisible.
    4. Add a Submit button with advanced interactions to show Continue or Wrong depending on what is chosen in the widgets.
    The full set of conditions and actions are:
    IF vTestWidget1 is equal to Right
    AND vTestWidget2 is equal to Right
    THEN Show Continue
    ELSE Show Wrong
    The problem
    I run this and only ever get the ELSE response (i.e. I can select two Rights and the Submit button still displays the Wrong text box).
    Possibilities
    I'm missing some sort of formatting around the text?
    I need something like a submit button for each widget to prompt an update in their associated variables?
    Can anyone help?

    Thanks, for the help guys. However...
    I have triple-checked my variable naming and can't see any problem.
    What I did do was eliminate the "Choose" option from the head of each widget. The demo suddenly worked perfectly!
    BUT  that perfect outcome seems accidental.
    The demo seems to work ONLY when the Advanced Action's success conditions refer to the first entry on each dropdown. That is, if the dropdowns contain values Right and Wrong, IN THAT ORDER, and the Action looks for "Right" and "Right" then you can click Submit and it produces the Continue button.
    However, for example, if you reverse the order of the entries in one widget, so Widget2 contains Wrong and Right, and YOU DON'T TOUCH ANYTHING ELSE, then selecting "Right" and "Right" and clicking the Submit button produces the Wrong text box response.
    So the order in which entries are listed in the widget has an impact, at least for me.
    When you guys replicated my use case, did you replicate the Choose entries in the widgets, or did you simply have two top-level Right responses?
    I've uploaded my first demo, without any other changes, to Google Docs, if you want to check it:
    https://docs.google.com/leaf?id=0Bz2ZZ5mfN3BkMjc1N2U3ZjgtZWZmMC00MmVlLWE3Y2UtZTczMzM5ZjI1N GMx&sort=name&layout=list&num=50

  • How to Get checkbox value when List value changed in classic report

    hi ,
    i worked with apex 4.2 and i create normal classic report with one checkbox column and one column change it to select list(named loved) now i want when user change list
    take value of checkbox item and show it in message .
    SQL for report
    SELECT
    '<INPUT TYPE="checkbox" NAME="f01" VALUE="'
    ||SEQ
    ||'">' SEQ,
    ID,
    DEPT_NO,
    EMP_NAME} i change the column attributes of Dept_NO to Display as Select list of department name (named lov).
    now i want when user change name of department the value of SEQ SHOW IN ALERT MESSAGE
    i create JavaScript on the page
    function test(pThis) {
    var f01_value = $('select[name="f01"]').value;
    alert('#SEQ : '+ f01_value);
    </script>
    I call this javascript function when list change but the value undefined..
    My Question :
    How can get this value Or any value of item in reports
    regards
    Ahmed

    Hi Ahmed,
    >
    i worked with apex 4.2 and i create normal classic report with one checkbox column and one column change it to select list(named loved) now i want when user change list
    take value of checkbox item and show it in message .
    SQL for report
    SELECT
    '<INPUT TYPE="checkbox" NAME="f01" VALUE="'
    ||SEQ
    ||'">' SEQ,
    ID,
    DEPT_NO,
    EMP_NAME} i change the column attributes of Dept_NO to Display as Select list of department name (named lov).
    >
    You should not create checkboxes like this. Either use the APEX_ITEM.CHECKBOX2 API or change the Column Type to Simple Checkbox.
    >
    now i want when user change name of department the value of SEQ SHOW IN ALERT MESSAGE
    i create JavaScript on the page
    function test(pThis) {
    var f01_value = $('select[name="f01"]').value;
    alert('#SEQ : '+ f01_value);
    </script>
    >
    name="f01" returns an array, what you need is single element value.
    Try
    <script type="text/javascript>
    function test(pThis) {
      var f01_value = $v(pThis);
       alert('#SEQ : '+ f01_value);
    </script>
    {code}
    {quote}
    I call this javascript function when list change but the value undefined..
    My Question :
    How can get this value Or any value of item in reports
    {quote}
    Depends in how you are invoking/triggering the change event. Are you using DA or have you written an "onchange" event on the element?
    Cheers,                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                   

  • How to get the view Object in UserDefined Action

    Hi  All,
       Any body tell me how to get the view object , like the view object avilable in the wdDoModifyView() method as parameter.
    I have requirement like, i want to change the , no of rows displaying in the table should be changed at the runtime based onthe no of rows  selected in the dropdown box.
    The action which i created will be assigned to that dropdown box, on select of the available option, i will get the view object and change the properties of the "maxrows" of the table .
    so for getting the view object in the  the Action methods tell me what is the procedure for getting the current view object.

    Hello Vishal,
    Simply create a value attribute (say rowCount) of type 'integer' and bind it to the 'visibleRowCount' property of your table. Then, in the actionHandler get the value from the UI element (in your case, I guess it is drop down) and set it to the attribute 'rowCount' like this.
    wdContext.currentContextElement.setRowCount(
        wdContext.current<nodeElement>.set<AttributeBound toDropDown>);
    Bala

  • How to get field action property in a pdf form

    Hi all,
    In pdf form, there is a Radiobutton field is there.
    Now i want to create a checkbox with same properties what and all Radiobutton is having.
    I got the all the properties from Radiobutton and created checkbox except "Actions".
    I checked with documentation In that i come to know we can able to add script by addJavaScript or able to set actions by setAction.
    Is there any possibility to get Action properties from a field???
    Please if anybody know let me know.
    Thanks and Regards,
    Christy

    Thanks a lot for your answer.
    I have one more doubt
    In Acrobat 5 we can easily change field type by selecting changetype option, the only thing we need to give diff name for the field it will change type what we changed with the properties what and we had in old type.(I m explaining here about radio To checkbox).
    If it is possible can u please explain in what basis it is working.
    Thanks and Regards,
    Christy

  • How to get the table Event action in the controller???

    HI
    Based on my requirement i have extended my controller,but i want to perform some validation like ,,,,
    i have table in one region ,in which one column is having a Button (flex field) action with image,
    i want to write the code in the controller according to the validation ,,,,but i am unable to find the event action in the main controller,
    how to get the event action ?,,,,, of the item type as image
    thanks in advance
    Kash

    If not you can use image component with clientListener and serverListener to preform your requirement set clientListener click event and then inside clientListener java script method call the
    serverListener then will execute serverListener method.

  • How to get the Application perform actions when exits?

    How to get the Application perform actions when user clicks on the "X" icon in the top right hand corner?
    OR
    If i placed an Exit Button.... when actions that i need to use to allow my application to perform a certain action when it exits?
    Thanks

    frame.addWindowListener(new WindowAdapter() {
      public void windowClosing(WindowEvent e) {
        // do your stuff here
    });The WindowListener and WindowEvent can be found in java.awt.event package
    //David

  • How to get the checkbox value

    Hi,
    i am working in Oracle APEX. Can anyone tell me how to get the checkbox value Thru Pl/sql Procedure.
    Ex:
    if i have three users like 1) super admin 2) HR 3) user i am giving different grants to all. there s a check box i used if HR selected three grants i have to get the checked value from my procedure and put into a table in a single column.
    grants :
    1)user creation
    2)salary details
    3)Attendance details
    4)Allowance
    5)contacts
    if its checked i am returning 1 not checked i hav to return 0
    in my table i ahv to store 10111 like that......
    Edited by: user12356342 on Dec 16, 2009 3:33 AM

    Hi,
    As a starting point, look at: [http://download-uk.oracle.com/docs/cd/B31036_01/doc/appdev.22/b28839/check_box.htm#CHDCGIFA] as this explains how to use checkboxes on forms and reports
    Andy

  • How to get all the values of a variable with F4 with checkboxes to select

    Dear Experts,
    After Executing a query by giving let 3 values(Out of 10 Values) to a variable.
    To give 2 more input values to the same variable(i.e.,total I wanted to give 5 inputs this time ),after refreshing the query,for that variable if I click F4, I am seeing the historical values(i.e.,3) and remaining 7 values also But with out any Check Boxes besides them to select the 2 inputs.
    In the same F4 Screen, If I click all values(an Icon at The bottom),then also Im seeing but no check Box.
    I hve tried by deleting the Delete Personalization also,but no use.
    Please tell me How to get all the values with F4 with check boxes to select ,whatever I want??
    Thanks in advance

    Take a look at the InfoObject and go to the Business Explorer tab. If the 'Query Def. Filter Value Selection' is set to 'Only Values in InfoProvider', you're only going to get the values in F4 that exist in the InfoProvider, not everything in the Master Data. This would need to be changed to the value of 'Values in Master Data Table' if you want it to show everything possible when F4 is chosen.
    Likewise, you're going to need to look at the query and go to the Advanced tab for the InfoObject. Make sure that the radio button for 'Values in Master Data Table' is selected. If not, then you should change that selection.

Maybe you are looking for