Can I use my javascript to change the session state of an item?

All,
I currently have a page that has two regions: a report and a checkbox region. The checkbox region is full of checkboxes that are tied to each column in the report. I have javascript in the page HTML header that hides/displays the report column when they click the corresponding checkbox. The hiding and displaying columns works just fine.
Here is my problem: my users need to export the report (with some columns hidden) as a CSV file. Unfortunately, the javascript function I use to hide/show the columns does not change the session value of the checkbox region and thus, APEX does not 'know' that some columns have been hidden. Because of this, APEX exports ALL columns.
Can I add an onChange to my javascript that each time the user checks/unchecks a box, it adds/removes that item from the checkbox region's session value?
Thanks!
BoilerUP
P.S. I do not want to submit the page - I would like for this to be done on the fly, just like the columns hiding/appearing with the javascript. Thanks!
Message was edited by:
BoilerUP

Ok, I still cannot get this to work. I keep getting a javascript page error (yellow exclamation icon in I.E.) I have the following code in the HTML header:
<script language="JavaScript" type="text/javascript">
function va_GetCheckboxes(pName)
var d=document;
var l_return = "";
var inputs=d.body.getElementsByTagName('INPUT');
var l_el;
for (var j=0;j<inputs.length;j++) {
     l_el = inputs[j];
     if (l_el.type=="checkbox" && l_el.name && l_el.name==pName
         && l_el.checked) {
            l_return += ":" + l_el.value;
return l_return.substring(1);
</script>I also have the following code in the HTML Form Element Attributes section for the checkbox item:
onclick="html_HideBasedOnCheckBox(this,this.value);set_Some_Item('P2_COLUMN_HIDE_CHECKBOXES',that_string)"Do I need to replace "that_string" with something or is there something else that I'm doing wrong?

Similar Messages

  • Since I changed the operating system Windows 7 32bit to 64bit I can not use Firefox browser unless change the browser to safe mode.

    Since I changed the operating system Windows 7 32bit to 64bit I can not use Firefox browser unless change the browser to safe mode.When i start it the browser is not open and appears a message
    Mozilla Crash Reporter
    == Crash ID(s) ==
    20100611143157
    == User Agent ==
    Mozilla/4.0 (compatible; MSIE 8.0; Windows NT 6.1; WOW64; Trident/4.0; SLCC2; .NET CLR 2.0.50727; .NET CLR 3.5.30729; .NET CLR 3.0.30729; Media Center PC 6.0; .NET4.0C; .NET4.0E; InfoPath.3)

    the 20100611143157 is an update which won't instal automatically on my notebook

  • Using a javascript to change the font size used by the measurement tool

    A couple years ago I saw a javascript written that would allow me to chang the font size used by the measurement tool in Acrobat 9.  When the IT department deliverd my new laptop with Acrobat X Pro, they had wiped out the script and I am not expert enough to recreate it from scratch.  Any suggestions?  I believe it was in an older post by Dave Merchant, but I truly can't find the post or a way to recreate the script.  Thanks for any help.

    Executing this code from the JS console will change the font size of all the Measurement annotations to 20. You can change the value in the first line to use a different font size:
    var newTextSize = 20;
    this.syncAnnotScan();
    var annots = this.getAnnots();
    for (var i in annots) {
        var annot = annots[i];
        if (annots[i].type=="Line") {
            var richText = annot.richContents;
            for (var i in richText) {
                richText[i].textSize = newTextSize;
            annot.richContents = richText;

  • Can I use a javascript variable for the ID of a module ?

    I want to use a javascript variable to pull up the related media downloads.
    So instead of using a hard coded
    <div id="media">
      {module_literature,c,45243}
    </div>
    I want to use jQuery to render the right category of media downloads ... Something like:
    <div id="media">
         new text would go here
    </div>
    <script language="javascript">
         var id = 45243
         $('#media').html({module_literature,c,id})
    </script>
    Ive also Tried the following
    <script language="javascript">
        var id = 45243
        var str = '{module_literature,c,'+id+'}"
         $('#media').html(str)
    </script>
    Niether seems to work ?

    Hi Brad
    I want to eventually change the id to a variable that is changed elsewhere on the page via jquery
    But I can seem to get either of the above to work ?
    I seem to get Unexpected token illegal messages when using the above script

  • Can I use iPhone 5S A1530 in the United States?

    I live in Hong Kong and bought a iPhone 5S A1530 model few months ago. I will go to exchange to the United States for half year. Is my iphone 5S compatible for US LTE network?? Which US carrier can I use?? What should I do to use celluar network in US if LTE is not supported??

    I happen to have a similar problem as well. I currently live in Hong Kong, and will be going to the US in August.
    My iPhone 5s is still in warrantly by then. Is it possbile for me to arrange an exchange for a US version in Hong Kong or US?

  • Can I use Find & Replace to change the fills and strokes of tables?

    I'm working on a catalog that has a fair amount of tables, that all have the same color scheme.  I need to change all of these tables to a new color scheme, and I'd much rather find a way to do it with one shot.  The tables do not have styles applied to them, so it's not a matter of adjusting the style definitions.
    I know you can do a Find & Replace for text or objects in a specific color. Is there a way to do the same for table cells?  I've tried but haven't had luck getting it to work.
    Thanks!
    -Sean

    Congratulations are in place -- changing parameter names in the right places is one thing, finding out what parts safely can be copied is step 2 in my book "how to become a successful scripter in 10 easy steps"
    You cannot select more than one table in Table mode, but what you can do is select them together with its surrounding text -- just keep on dragging that mouse until you've covered them all. The InDesign Selection is a multi-purpose object (see the way the script has to find out "what is selected"), and one of the things it keeps track of is how many and which tables are "inside" the selection. Then run this slightly amended script:
    a = app.selection[0];if (a.tables.length == 0)
    alert ("You must be kidding; not a single table inside your selection!");
    exit(0);
    for (b=0; b<app.selection[0].tables.length; b++)
    d = app.selection[0].tables[b]; // shortcut
    for (c=0; c<d.cells.length; c++)
      if (d.cells[c].fillColor == app.activeDocument.swatches.item("Bloo"))
       d.cells[c].fillColor = app.activeDocument.swatches.item("Redd");
      // .. Insert more colors here ..
    Now the script doesn't have to check anymore in which part of the table you clicked; it only has to iterate over the ones in your selection, and those are "immediately" accessible through the indexes (the square bracketed variables). And the "shortcut" is so I don't have to type "app.selection[0].tables[b].cells[c].fillColor" every time. (And the script runs marginally faster as well, although it's probably still almost immediate.)

  • Trouble setting the session state of a select item.

    Hi,
    I have a requirement whereby I need to change the session state of a select list item in my form without the need to submit. I am using Application Express 4.1.0.00.32. I thought this would be straight forward using a dynamic action or javascript and calling an on demand process for example.
    P1_MY_SELECT onchange="set_option();"
    function set_option() {
    var l_option=$f_SelectValue('P1_MY_SELECT');
    alert( 'My new value is ' + l_option );
    // ON DEMAND Set the new session state value
    var lRequest = new apex.ajax.ondemand
    ('SET_P1_MY_SELECT',function()
    {  /* start the return function */
    var l_s = p.readyState;
    if(l_s == 1||l_s == 2||l_s == 3)
    else if(l_s == 4)
    { gReturn = p.responseText;
         (gReturn)?json_SetItems(gReturn):null;
    else{return false;}
    /* end the return function */
    lRequest.ajax.addParam('x01', l_option );
    lRequest._get()
    My on demand application process
    DECLARE
    l_options varchar2(2000) := wwv_flow.g_x01;
    BEGIN
    APEX_UTIL.SET_SESSION_STATE('P1_MY_SELECT',l_options);
    apex_util.json_from_items('P1_MY_SELECT');
    END;
    Is there a better method to set the session state of my P1_MY_SELECT other than what I am doing as above or can you tell me why the session state of P1_MY_SELECT is not changed?
    Thanks.
    Edited by: 968358 on 01-Nov-2012 08:40

    if you are on 4.1 why don't you use a dynamic action instead of writing the code again?
    create a dynamic action like this
    Event: Change
    Source Type: Item
    Item: P1_MY_SELECT
    True Action:
    =========
    Action: Execute Plsql Code
    Plsql Code: null;
    Page Items to Submit: P1_MY_SELECT
    Page Items to Return: P1_MY_SELECT (this is optional)
    http://docs.oracle.com/cd/E23903_01/doc/doc.41/e21674/advnc_dynamic_actions.htm#HTMDB27020

  • Using javascript to change the "Overall Result" cell in WAD

    Hi experts,
    I am trying to use javascript to change the text of the "Overall Result" cell in my web template using BI 7.0. I am not familiar with javascript, but I this is what I have done so far.
    I dragged the web item "Script" into my web template and I inserted the following code:
    function change_overall_result_to_average() {
    var cell = document.getElementsByTagName("TD");
    var cellText;
    for (i = 0; i < cell.length; i++)
          cellText = cell<i>.innerText;
               if (cellText == "Overall Result")
                     cell<i>.innerText = "Average";               
    In the XHTML view I am using added the onload function to start the javascript every time the web template is loaded. The code works fine when the web template is first loaded and the cell text is changed to "Average". However, if I navigate in my web template, the javascript function is not triggered, and the cell is therefore changed back to "Overall Result". For example, this happens when I pick another selection from one of my dropdown boxes, such as changing the selection from year 2008 to year 2007.
    I don't really know how to solve this problem in an easy way, and the current solution is not good enough. I hope one of you guys can suggest an easy way of fixing this:-)
    Best Regards,
    Morten

    Woodstock apparently renders some Javascript/DOM with some homegrown widget framework which on its turn renders the HTML DOM tree instead of plain vanilla HTML. Correct me if I'm wrong, to confirm this, just view the generated HTML source of the page.
    After some Googling I found out that you need getProps() and setProps() to get and set element attributes respectively.
    [http://google.com/search?q=webuijsf+domnode+site:sun.com].
    If you stucks with this, I recommend you to post this question at a forum or mailinglist devoted to Woodstock, e.g at their own homepage at dev.java.net or the Netbeans forum at nabble.com. You're here at a Sun JSF forum, not at a Woodstock forum.

  • I have a new Macbook pro and can't recall the password I used with my Time capsule - How can I (ideally) retrieve or possibly change the time capsule password?

    I have a new Macbook pro and can't recall the password I used with my Time capsule - How can I (ideally) retrieve or possibly change the time capsule password?

    Remember security on a TC is an illusion.
    Simply press the reset button for 1-2 sec.. you must not do too long .. it will then hard reset.. but soft reset will revert all passwords to default for 5min. ie TC password is now public.
    Remember this the next time because anybody at all can change your passwords.
    Once into the TC you can then open the view passwords if you wanted any weaker security. Click and open the TC.. and click on edit.. then go to the top menu..
    Voila .. all your passwords in plain sight to any Tom Dick and Fred.

  • After i bought mac os x lion from web then download , after that to install but when they ask me to choose disk to install i can not choose, it say this disk does not use the GUID partiton table scheme. use disk utility to change the partition scheme. but

    after i bought mac os x lion from web then download , after that to install but when they ask me to choose disk to install i can not choose, it say this disk does not use the GUID partiton table scheme. use disk utility to change the partition scheme. but

    after i bought mac os x lion from web then download , after that to install but when they ask me to choose disk to install i can not choose, it say this disk does not use the GUID partiton table scheme. use disk utility to change the partition scheme. but

  • Can the new iPhone 5s bought from US be use in Asia by changing the SIM card?

    Can iPhone 5 bought from US use in Asia by changing the SIM card?

    an UNLOCKED ( only from Apple ) iPhone 5 will work on 3G but unlikely it will support 4G in your country
    http://www.apple.com/iphone/LTE/

  • Can we use idoc technique to change or delete the vendor master data?

    Hi,gurus,
    Can we use idoc technique to change or delete the vendor master data?You know we can create vendor data using idoc CREMAS03 as the receiver adapter,but when change or delete the specified vendor data,must we use RFC adapter technique?
    Another question:I found the bapi which creates a vendor master data doesn't have the parameter account group,then we turned to idoc technique.But which adapter should I use when change or delete the vendor data?
    Thanks in advance.

    Hi,
    >>>I found the field of the segment of deletion flag at different level,and very appreaciate your help.
    yes - LOEVM  - but remember this will not delete the record but only mark it for deletion
    >>>It's a long time to wait for your new blog,what new and interesting things do you find?
    at least 4 new in my head - 2 simple but important and 2 new + I'd also like to write something for XI guys about
    BO data integrator which can also work as EAI tool (BTW I know it's ETL) but how knows when they will appear
    Regards,
    Michal Krawczyk

  • Can't figure out how to change the bottom margins

    This is my 3rd day with a mac and I can't figure out how to change the margins in Pages '09 so that it doesn't include a .5 margin on the bottom.
    I'm using a HP OfficeJet J6450. In the page setup, I changed the "untitled" user defined margins to .1 for top and sides and 0 for the bottom and it still includes a .5 margin on the bottom. Changing the untitled seems to help side margins.
    I've used the inspector to see if there is a setting there that defines the bottom margin as .5 and that doesn't seem to do it.
    If I print borderless, the text boxes that I have a .3 border around don't print on the edges even though they show up on my workspace. It also throws off the top and bottom.
    This is a big assumption, but I assumed that if the workspace and rules show white space and now grayed out, it would print that way. It's not.
    Any ideas? Thanks! Ana
    P.S. I've downloaded & installed updates for everything - OS, iWorks, Printer

    Peggy,
    Maybe this is true of Macs? On my windows systems - I can specify more options on both my printers and can print beyond .5 inches at the bottom. One specific option on my J6450 that I can select is "minimize borders" and it will print about .1 or .2 from the edge. On my mac, I do not have that feature to select. If I print borderless, even though my layout shows it should not go off the paper, once printed it does.
    Thanks.

  • Hi, I recently changed my username for my iTunes/iCloud account. Can anyone tell me how i change the username on my iCloud iPad? When I go onto setting to change it it keeps the username grey so I can't even select it?

    Hi, I recently changed my username for my iTunes/iCloud account. Can anyone tell me how i change the username on my iCloud iPad? When I go onto setting to change it it keeps the username grey so I can't even select it?

    Welcome to the Apple Community.
    In order to change your Apple ID or password for your iCloud account on your iOS device, you need to delete the account from your iOS device first, then add it back using your updated details. (Settings > iCloud, scroll down and hit "Delete Account")
    Providing you are simply updating your existing details and not changing to another account, when you delete your account, all the data that is synced with iCloud will also be deleted from the device (but not from iCloud), but will be synced back to your device when you login again.
    In order to change your Apple ID or password for your iCloud account on your computer, you need to sign out of the account from your computer first, then sign back in using your updated details. (System Preferences > iCloud, click the sign out button)
    In order to change your Apple ID or password for your iTunes account on your iOS device, you need to sign out from your iOS device first, then sign back in using your updated details. (Settings > iTunes & App store, scroll down and tap your ID)
    If you are using iMessages or FaceTime, you will also need to log out and into your ID there too.

  • How can I create a navigation bar in the template so I can change the down state of a button on a page made from the template in DW3?

    We're creating pages from a template in DW3. The template includes a header, footer and a navigation bar. We've made the navigation bar an editable region so that we can change the down state of the buttons on pages where it is required. However, when we make a new page from the template and try to change the behaviors of the buttons in the navigation bar it will not allow us to make those changes. 

    Have you considered using CSS styled text/list menus instead of image rollovers.  It isn't hard really and it's actually a much better choice for   web accessibility and for search engines to find and follow your links.   Here are some links to several CSS menu systems you can try:
    CSS Express Drop-Down Menus (tutorial)
    http://www.projectseven.com/tutorials/navigation/auto_hide/
    CSS Tab Designer creates 60+ CSS Styled Button and Tab Menus  (download)
    http://www.highdots.com/css-tab-designer/
    List-O-Rama  (DW Extension)
    http://www.dmxzone.com/go?5618
    CSS  Menu Maker (On-Line Menu Generator)
    http://www.cssmenumaker.com/
    Pop-Menu  Magic2 by PVII (DW extension purchase)
    http://www.projectseven.com/products/menusystems/pmm2/index.htm
    Nancy O.
    Alt-Web Design & Publishing
    Web | Graphics | Print | Media  Specialists
    www.alt-web.com/
    www.twitter.com/altweb
    www.alt-web.blogspot.com

Maybe you are looking for

  • Final Cut Pro Video Playback not in Widescreen for Anamorphic Material

    I have a Panasonic DVX-100B hooked up to my computer and am running Final Cut Pro. I shot everything in the anamorphic squeeze mode. When I play this material back through my camera (which displays the material as widescreen because I forced it on th

  • Do You Have to Have a Password on iMac?

    I've found how to set a password and how to change one, but is there a way that you can set up the iMac so no password is needed on startup??

  • Oracle Integration Repository for API's.

    Where can I find the Oracle Integration Repository for all the API's related information for R12. Initially i used to go through this site http://irep.oracle.com/index.html for API related information for 11i, even this is not working. For R12 the In

  • I can't log in after I got a start up disk is full message, what do I do? ?

    I am having a problem logging in after a startup disk is full message. Is there anything I can do to get it to log in again? I have been deleting large files but I guess it wasn't enough to take care of the problem.

  • The iPod cannot be synced, error (-124)

    I have a brand new 80gb ipod. It synced once and then the battery ran completely down and I had to restore it. Since then, after syncing one or two podcasts, I get the error message listed in the subject. I have tried the whole 5R's to resolve the pr