With the help of APEX_JSON translated by JavaScript and escape the quotes

I am currently generation JSON using the APEX_JSON package.  It works fine, but I got out the JavaScript code on the loading of the page and can not find a way to escape the double quotes.

function drawChart() {


        var jsonData = &P9_JSON.;


        var data = google.visualization.DataTable(jsonData);


        var options = {
          title: 'Test Chart',
          pieSliceText: 'value'
        };


        var chart = new google.visualization.PieChart(document.getElementById('piechart'));


        chart.draw(data, options);
      }

I'm getting errors because "is replaced by & quot;" in the javascript code generated.  Any ideas how to replace these?  I tried to use to replace them, but it doesn't seem to work...

Thank you!

Hi LSDev

Replace this line--> var jsonData = & P9_JSON. ;

To--> var jsonData = & P9_JSON! RAW. ;

This work for me...

Best regards

Eduardo

Tags: Database

Similar Questions

  • By using the quote delimiter with set off.

    I have problems with the quote delimiter pick up the colon as a variable binding. For some reason any where there is a colon infront tick it break (ex. 2) but in (Exodus 3) he is behind the colon, it works perfectly.

     set define off
    DECLARE
     s1 VARCHAR2(20);
     s2 VARCHAR2(20);
     s3 VARCHAR2(20);
    BEGIN
      s1 := 'Isn''t t:his cool';
      --s2 := q'{Isn't th:is cool}';
      s3 := q'{Isnt th:is co'ol}';
      dbms_output.put_line(s1);
      dbms_output.put_line(s2);
      dbms_output.put_line(s3);
    END;
    /

    In this case simply update your client. From your database in version 10 already, you must also use a client version 10.

    9i and 10g client can be installed on a PC without a problem alnongside. It's just that the 10g client is installed with a little more subfolders. Maybe you have already installed and just continue to use the old client (old link?).

    On a windows client system 10g would be in a structure like this: file://c:/oracle/product/10.2.0/client_1/bin

    whereus 9i client is in: file://c:/oracle/ora92/bin

    Published by: Sven w. on July 21, 2011 19:33

    Published by: Sven w. on July 21, 2011 19:36

  • With the help of JavaScript condition in the dynamic action of JQuery selector

    Hi guys,.

    I have a Setup master detail on a page.

    The detail section, I have a tabular presentation.  One of the fields is a selection list.  The first record in the select contains the value * not * that has a value of primary key for the 1.  I have a distinct region with a simple text field where the user can insert a value into the table if the value does not exist.

    I want than the region of text element to only appear if the value * not listed * is selected.

    I managed to make it work when the value is selected with the help of dynamic action with a bit of JQuery and JavaScript by setting the ID on the selection list to 'create' and have the following in JavaScript $(this.triggeringElement) .val ()! = 1 in the JavaScript for dynamic action condition shows it or hides the region of 'create' and that works well.

    However, if the secondary table is empty before the detail records were created (nothing selected in triggering jQuery Selector) the region of create is displayed when I don't want it.

    I guess I need some sort of NVL in JavaScript condition?

    I use APEX v4.2.

    Any advice would be appreciated.

    Chris

    Cashy wrote:

    I have a Setup master detail on a page.

    The detail section, I have a tabular presentation.  One of the fields is a selection list.  The first record in the select contains the value * not * that has a value of primary key for the 1.  I have a distinct region with a simple text field where the user can insert a value into the table if the value does not exist.

    I want than the region of text element to only appear if the value * not listed * is selected.

    I managed to make it work when the value is selected with the help of dynamic action with a bit of JQuery and JavaScript by setting the ID on the selection list to 'create' and have the following in JavaScript $(this.triggeringElement) .val ()! = 1 in the JavaScript for dynamic action condition shows it or hides the region of 'create' and that works well.

    However, if the secondary table is empty before the detail records were created (nothing selected in triggering jQuery Selector) the region of create is displayed when I don't want it.

    I guess I need some sort of NVL in JavaScript condition?

    I use APEX v4.2.

    Simple solution is to hide the region containing the element of text by default, using the style = "" view: no ' in the property of the attributes of the area in the region. " It will be always hidden when the page initially, but its visibility will be controlled by the DA subsequently.

  • Help with the JavaScript for checkbox

    I am a newbie with Javascript and will have questions, get the selection of a checkbox on my form to change a calculation.

    I have a form that contains two drop-down lists, the result of these two boxes are multiplied together.  I can get it works fine.

    However, I also have a box that, when checked I want the calculation according to the drop-down lists duplicate.  I can't get that part to work!

    Can anyone provide the javascript code to activate this simple event?

    Any help is appreciated.

    Thank you.

    It should look like this:

    Get field values

    var v1 = combo1.value;

    var v2 = combo2.value;

    $ var = + v1 + v2;

    Get the value of the checkbox

    var v3 = getField("checkbox1").value;

    Calculate the value of this field based on the State of the checkbox

    V3 = Event.Value = "Off"? sum: 2 * sum;

    This last line is equivalent to the following five lines:

    If (v3 = 'Off') {}

    Event.Value = sum;

    } else {}

    Event.value = 2 * sum;

    }

  • Please, do I have with the help of Javascript can change the values of tones? for example my color of nail POLISH with c: 0, m:10, y: 15, k: 0 to change to c: 0, m:0, y: 0, k: 0? Thank you

    Please, I beg you, with the help of Javascript change the values of specific spot color? for example, I have the color called VARNISH with c values: 0, m:10, y: 15 k: 0 and it would help me to change to c: 0, m:0, y: 0, k: 0, in an action. Is this possible? Thank you

    Hello Kon Verter,

    You can change the values in your sample of spot, but you need to check a lot of things before.

    for example, you can do something like this:

    var Vcolor = app.activeDocument.swatches.getByName("Varnish");
    if (Vcolor.color.spot.colorType == ColorModel.SPOT && Vcolor.color.spot.spotKind == SpotColorKind.SPOTCMYK) {
        alert("Black value before: "+Vcolor.color.spot.color.black);
        Vcolor.color.spot.color.black= 0; // and so on
        alert("Black value after: "+Vcolor.color.spot.color.black);
        }
    

    This will change the black value of the task of CMYK color with name Nail Polish 0

    Have fun

  • assignment source src, with the help of javascript required

    Hi all

    I would like to fill this line:

    < source src = "audio / mysong1.mp3" >

    with the javascript var = song

    but I'm not sure how to do it...

    I tried this instead of the real line (in the same area)- but it did not work:

    var t = document.createTextNode ("< source src ='audio/mysong2.mp3" > "");

    document.body.appendChild (t);

    suggestions are welcome - thanks

    < script >

    song var = "mysong2.mp3";

    < /script >

    < div id = 'wrapper' >

    < audio preload = 'auto' controls >

    < source src = "audio / mysong1.mp3" >

    < / audio >

    < / div >

  • Problem with the help of the $s javascript function to fill a page element

    Hello Oracle APEX community,

    I work on a page dashboard of exploration down and have been a problem when I try to fill a Page of text (hidden or not) element using javascript built in function $s.
    The feature works very well when the data is a number such as dept_id (even if the field type is varchar type). However, trying to pass what is a text the process fails, unless a value is hardcoded as parameter to the function. So, for example, I have a table with constituents by State counties. I would like to fill out (filter) a table based on when you click a bar for a State without having to submit the page. I use dynamic actions and built in javascript function in the SQL code for the graph to achieve; But even once, it works fine when I use a field varchar as the FIPS code (FIPS for Texas is "48"), but when I try to fill the page element by using the abbreviation of the State "TX" (new varchar), it fails.

    Here is an example of code that works:
    SELECT 'javascript:$s("P1_DEPTNO",'||d.deptno||')' LINK,
    d.dname LABEL,
    sum(e.SAL) sal
    FROM emp e, dept d
    where e.deptno = d.deptno
    group by 'javascript:$s("P1_DEPTNO",'||d.deptno||')', d.dname 
    And here is an example of code that does not work:
    SELECT 'javascript:$s("P1_DEPTNO",'||d.loc||')' LINK,
    d.dname LABEL,
    sum(e.SAL) sal
    FROM emp e, dept d
    where e.deptno = d.deptno
    group by 'javascript:$s("P1_DEPTNO",'||d.loc||')', d.dname 
    However, when I hard code a value the script text works:
    SELECT 'javascript:$s("P1_DEPTNO","BOSTON")' LINK,
    d.dname LABEL,
    sum(e.SAL) sal
    FROM emp e, dept d
    where e.deptno = d.deptno
    group by 'javascript:$s("P1_DEPTNO","BOSTON")', d.dname
    ORDER BY d.dname 
    I encounter this problem on several versions of the APEX: (4.0.2.00.07 - local installation) and (4.1.0.00.28 - apex.oracle.com)

    Does anyone know of this problem and how to solve? I have looked for the parameters of the element of the page itself and can not understand.
    I rewrote my sql to use the fields of value of my tables instead, but I have a few objects on the page that will really depend on the data of base characters instead.

    Thank you
    Wayne

    In your javascript that you generate, surround your value with quotes and it will then should always work with the numbers and strings (your channels are probably interpreted as variable names and that they do not exist when running, so slip out).

    Example:

    SELECT 'javascript:$s("P1_DEPTNO","'||d.loc||'")' LINK,
    

    Published by: gti_matt on August 16, 2011 09:50

  • With the help of beaches of text style in order to preserve the styles (Javascript CS3)

    Hi - I was hoping that someone could be so kind to help me with the text style varies.

    I know how to get the content of the story of parent of the image and place them in another framework, but I would like to preserve the styles. In a previous post, it was mentioned that a loop in the ranges of text style could accomplish this.

    Could someone please show me an example of how this could be done? I'm stumped on how to collect the content using text style beaches.

    Thanks in advance

    You cannot simply use Story.duplicate ()?

  • Failed to create the menu popup JavaScript with to display the context Menu with the help of add behaviors

    Whenever I load a page with this added behavior and test it with my link, I get a message "error on Page".

    Here's what I do:

    Create a new HTML page in Dreamweaver 8.0.2 and save it.

    Add a hyperlink in the Insert-> menu hyperlink. Do not put anything in it except a few example of text; "THIS IS a TEST", or something.

    Select the hyperlink and choose "Show the context Menu" in the tag behaviors menu tab ' + '. The dialog box will appear.

    Add a single item and add a link to a page. Do not change the other options. Click OK to close the dialog box and the code will be added to the page.

    Save the HTML page again and press F12 to load the page on your test server and display them in a browser.

    Hover your mouse over the link to test. Nothing happens and there is a message in the status bar at the bottom of the browser, "error on Page".

    OK, it works. I saw the source file that are listed there, but I assumed that Dreamweaver would be to download the file with the HTML file to test on my test server. Usually, I'm prompted to download all the dependent files. Is there an exhibitor or dreamweaver do not miss this link?

    I'm sold on convictions explained in the rants you have linked, but only after I see that Dreamweaver menus don't work. It is not entirely necessary for my completely dependent users of my menus, they are only a feature of page layout.

    Since I have the ear, maybe you could tell me something before my attempt it: is it possible to generate the JavaScript using PHP? I would like to include JavaScript in the context of records with PHP MySQL. Is there another possible solution from PHP? I guess that ASP is a solution already and maybe Flash too.

    This is the kind of page I'm working on that:

    http://www.symbiota.com/MiloTrial/witnesses.php

    I would like to see a drop down menu for each trial where the number of witnesses is less than 10 to save someone the trouble to open a new page just to see a list of ten names.

  • Problem with the translation into Chinese of msgrte.txt

    With the help of LabWindows/CVI 2012 SP1.

    I am trying to create a Chinese version of one of our applications. I have a msgrte.txt that has been translated into Chinese, and I ran countmsg.exe on update magic numbers. Countmsg.exe reports of success, and the numbers are changed.

    I replaced the following files with the new msgrte.txt for testing purposes:

    C:\Windows\SYSWOW64\cvirte\bin\msgrte.txt

    C:\Windows\SYSWOW64\cvirte\bin\msgrt4.txt

    C:\Windows\System32\cvirte\bin\msgrte.txt

    When I run the application, it blocks (unrecoverable error) whenever I do anything that requires the text in this file, for example a FileSelectPopup.

    If I use the standard version of English to msgrte.txt, the application works OK (though of course the standard popup panels have English text).

    An inspection of the eyeball of the msgrte.txt translated shows anything special on the file.

    Locale system is set to Chinese (simplified, China).

    Anyone has any ideas to identify the problem?

    I promised to report when a solution is found, so here it is:

    It turns out the format of at least some of the messages in msgrte.txt is critical and will result in the application crash if it is not correct. In my case, the message:

    1331 ' __All files (*.) " *)... »

    has been translated with a missing space character, that is to say (the Chinese equivalent of):

    1331 «files __All...»

    This message appears to be used as a filter in FileSelectPopup (and FileSelectPopupEx) specifier, so the space between the description and the designation of generic character is important.

    So if you translate msgrte.txt, be careful! If, like me, you find it translated by a third party in a language you don't understand, be doubly careful

  • Binary translation is incompatible with the long mode on this platform. Windows 7, processor intel core i5

    I install VMware Workstation 12.1.1 Player for Windows 64-bit operating systems on Lenovo intel core i5 Windows 7.

    I have a copy of VM for HP Quality Center with the VirXPSP3.vmx file and the environment.

    When I try to open the Workstation Player vmx file:

    (1) I got prompt that machine virtual seem to be an option to take possession and use

    2) after taking possession, I try to play the virtual machine, I got a prompt with "binary translation is incompatible with the long mode on this platform. Long mod will be disabled in the virtual environment and application requiring long mode does not work correctly as well. See http://vmware.com/info?id=152 for more details. »

    Link is on this page: system required to install an operating system 64-bit on a 32-bit host (1003945) client. VMware KB

    Host is definitely 64 so I'm puzzled with this is the case.

    (3) next step/guest is: "this virtual machine may have been moved or copied. I clicked on the button "I copied it".

    (4) the following message:

    Fatal error VMware Player: (mks)

    Exception 0xc0000005 (access violation) occurred.

    Log file is attached.

    Line 476 in the log file is:

    The following features of VT - x are necessary for the support of VT - x in VMware Player; However, these features are not available on this server:

    2016 06-07 T 13: 51:34.466 - 07:00 | VMX | I125: hostCpuFeatures = 0x217d

    In one of the previous installation, I did virtual Intel technology enabled in the BIOS after one of the responses of your forum. It has not removed the error.

    Just to clarify whenever I have uninstall I'm your site troubleshooting steps:

    (1) Uninstall using Add/Remove program of the program and features

    (2) run the installer with clean / change

    I do above steps as an administrator and restart after each step.

    On top I have delete the following folders:

    C:\Program Files (x 86) folder \Common Files\VMware

    File C:\ProgramData\VMware

    File C:\Users\Ivana\AppData\Local\VMware

    Files C:\Users\Ivana\AppData\Local\CrashDumps\vmware-vmx.exe.*.dmp

    File C:\Users\Ivana\AppData\Local\Temp\vmware-Ivana

    File C:\Users\Ivana\AppData\Roaming\VMware

    And delete the folder with the Virtual Machine for HP Quality Center.

    Do you know how can I fix a fatal error (mks)?

    The same installation works fine on HP with Windows 7, i.e. copy of VM for HP Quality Center is ok.

    Thanks in advance for your help.

    Usually, this is caused by outdated or incompatible graphics drivers on your host.  I expect that the latest drivers for your integrated Intel HD Graphics 4000 would be probably already delivered through Windows Update, however.  Could be interesting to see if there is an optional update in your Windows Update list to get a new graphics driver.

    Otherwise, you can try the problem by disabling 3D graphic acceleration: from the VM menu, select settings..., and then in the list of material , choose display.  Clear (uncheck) the box 3D graphic acceleration .

    I hope this helps!

    --

    Darius

  • helps with the update of tabular form using dynamic Action

    Hello world

    I'm trying to simplify a tabular presentation based on a collection so that it uses more dynamic actions that will be ultimately more easy for us to debug.

    Our tabular presentation is based on the query:

    SELECT
    apex_item.text(1,seq_id,'','','id="f01_'||seq_id,'','') "DeleteRow",
    seq_id,
    seq_id display_seq_id,
    c003,
    c004,
    c005,
    c006,
    apex_item.text_from_LOV(c004,'SPECIES')||'-'||apex_item.text_from_LOV(c005,'GRADE')||'-'||apex_item.text_from_LOV(c006,'MARKETCODE')||'-'||apex_item.text_from_LOV_query(c007,'select unit_of_measure d, unit_of_measure r from species_qc') unit,
    apex_item.select_list_from_LOV(8,c008,'DISPOSITIONS','onchange="getAllDisposition('||seq_id||')"','YES','0','  -- Select Favorite --  ','f08_'||seq_id,'') Disposition,
    apex_item.select_list_from_LOV(9,c009,'GEARS','style="background-color:#FBEC5D; "onFocus="checkGearPreviousFocus('||seq_id||');"onchange="getAllGears('||seq_id||')"','YES','3333','-- Select Favorite --','f09_'||seq_id,'') Gear,
    apex_item.text(10,TO_NUMBER(c010),5,null, 'onchange="setTotal('||seq_id||')"','f10_'||seq_id,'') Quantity,
     
    apex_item.text(11,TO_NUMBER(c011),5,null,'onchange="getPriceBoundaries('||seq_id||')"','f11_'||seq_id,'') Price,
    
    apex_item.text(12, TO_NUMBER(c012),5,null, 'onchange="changePrice
    ('||seq_id||')" onKeyDown="selectDollarsFocus('||seq_id||',event);"','f12_'||seq_id,'') Dollars,
     decode(c013,'Y',apex_item.text(14, c014,30,null,'style="background-color:#FBEC5D;" onClick="onFocusAreaFished('||seq_id||');"','f14_'||seq_id,''),'N','N/A') Area_Fished,
    c014,
    c015,
    c016,
    c017 additional_measure_flag,
    decode(c017,'Y',apex_item.text(18, c018,4,null,'style="background-color:#FBEC5D; "onBlur="setUnitQuantity('||seq_id||')"','f18_'||seq_id,''),'N','N/A') UNIT_QUANTITY,
    decode(c017,'Y',apex_item.text(19,'CN',3,null,'readOnly=readOnly;','f19_'||seq_id,''),'N','N/A') UNIT_COUNT,
    c024 fins_attached,
    apex_item.textarea(28,c028,3,null,'class="hms_info"','f28_'||seq_id,'') Explanation,
    decode(c024,'N',apex_item.select_list_from_LOV(29,c029,'HMSNATURE','class="hms_info"''onchange="saveNature('||seq_id||')"','YES','A','-- Select Nature of Sale --','f29_'||seq_id,''),'U',apex_item.select_list_from_LOV(29,c029,'HMSNATURE','onchange="saveNature('||seq_id||')"','YES','A','-- Select Nature of Sale --','f29_'||seq_id,''),'Y','N/A') Nature_Of_Sale,
    c030,
    c031,
    c032,
    c033,
    c034,
    c035,
    c036,
    c037,
    c038,
    c039,
    apex_item.select_list_from_LOV(40,c040,'HMS_AREA_CODE','style="background-color:#FBEC5D;" class="hms_info"
    ',null,null,null,'f40_'||seq_id,'')  HMS_AREA_CODE,
    c020 hms_flag,
    apex_item.text(41,TO_NUMBER(c041),5,null, 'class="hms_info"','f41_'||seq_id,'') Sale_Price,
    c042,
    c043,
    c044,
    c050 shark_flag
    from apex_collections
     where collection_name = 'SPECIES_COLLECTION' order by seq_id 
    

    Note that many of the fields referenced are c0xx... and really serve as place holders so that the c0xx = fxx.  It's awkward, like every time that a movement or move a column, it upsets the fxx value.   So, I tried to use the CLASS if possible.

    I have a dynamic action that had worked perfectly, until I moved one of the columns... and now, it seems not to work when I'm trying to update anything with the HMS_INFO or SHARK_INFO class.  Grrr.

    dynamic action: CHANGE COLUMN

    event: CHANGE

    selection type: JQUERY SELECTOR

    jQuery selector: input [name = 'f10'], input [name = 'f11'], input [name = 'f12'], input [name = "f24"], textarea [name = "f28"], select [name = "f40"], input [name = "f41"]

    true action1: defined value, expression javascript, set P110_ID = this.triggeringElement.id

    true action2: defined value, expression javascript, set P110_VALUE = this.triggeringElement.value

    true action3: run pl/sql,.

    declare
      v_attr number;
      v_seq number;
    begin 
      v_attr := TO_NUMBER (SUBSTR (:p110_id, 2, 2));
      select ltrim(substr(:p110_ID,5,4),'0') into v_seq from dual;
     
      safis_collections.update_column(v_seq,
                                      v_attr,
                                      :p110_value);
    end;
    

    the safis_collections.update_column package is:

    procedure update_column(v_seq in varchar2,
                            v_attr in number,
                            v_value in varchar2)
    is
    begin
       apex_collection.update_member_attribute (p_collection_name=> 'SPECIES_COLLECTION',
                         p_seq => v_seq,
                         p_attr_number => v_attr,
                         p_attr_value  => v_value);
    apex_debug.message('updated column. seq='||v_seq||' attribute='||v_attr||' with '||v_value);
    
    end;
    

    I wonder if there is a way to make the CLASS in my JQUERY SELECTOR, so something like reference entry [class = "HMS_INFO"], input [CLASS = "shark_info"]... and if so, what happens if a single item in the class is an option button and the other is a selection list and the other an element?

    is it possible to not have to rely on the fxx.  Currently, my collection columns map to the investment in the form of tables... sense, c024 = f24... because I placed c024 to be the 24th editable column, but this seems crazy.  Is there a simpler way?  I'm just learning class, then maybe there is something extra, or rather that I could use...

    any help is appreciated.   Thank you!

    I think I have solved the problem.

    dynamic action: CHANGE COLUMN

    event: CHANGE

    selection type: JQUERY SELECTOR

    jQuery selector: input [name = 'f10'], input [name = 'f11'], input [name = 'f12'], .shark_info, .hms_info

    true action1: defined value, expression javascript, set P110_ID = this.triggeringElement.id P110_VALUE POINT KEYS

    true action2: run pl/sql code

    begin
    null;
    end;
    

    items to submit page: P110_ID

    true action3: defined value, expression javascript, set P110_VALUE = this.triggeringElement.value P110_VALUE POINT KEYS

    true Action4: value: PL/SQL expression, the value P110_SEQ = rtrim (substr(:P110_ID,5,4),'0 ') CONCERNED POINT: P110_SEQ

    true Action5: run pl/sql code

    declare
    
      v_attr number;
    
    begin
      v_attr := TO_NUMBER (SUBSTR (:P110_id, 2, 2));
    
      apex_collection.update_member_attribute
                       (p_collection_name      => 'SPECIES_COLLECTION',
                        p_seq                  => :P110_SEQ,
                        p_attr_number          => v_attr,
                        p_attr_value           => :P110_VALUE);
    
    end;
    

    items to submit page: P110_ID, P110_VALUE, P110_SEQ

    true action6: refreshment area

    I think it is the combination of the use of pl/sql expression to calculate P110_SEQ and also your tip on TRUE ACTION2 to submit the item that did the trick.

    Thanks Kofi, for your patience and help!  It was great.

    Ugh... on the next issue.

    Karen

  • Problems with the help of text results in a table

    I am trying to create a script that returns a value based on a persons in a field name, but it does not work for me.

    This is the document level script:

    Here is the script I am trying to use it to get the variables (with the '0', I'm trying to shoot the first number in the table which is the age):

    event.value = personStats(getField("PersonName1").valueAsString)[0];
    

    Where "PersonName1" is the field that contains the name.

    This is the document level script that I use:

    var personStats = { 
        "Jim Bean" : [45, brown, 70, 175], 
        "Nancy Cardashian" : [36, black, 68, 122], 
        "Bobby Gentry" : [72, grey, 71, 165], 
        "Megan Foxx" : [28, black, 67, 126] 
    }
    

    and here is the error I get:

    personStats is not a function

    1:acroform:fumble Range 0:Calculate.

    TypeError: personStats is not a function

    1:acroform:age Range 0:Calculate.

    I hope someone can help. George?...

    Bruce

    Acrobat forms use a variant of JavaScript and adds a few objects, properties and methods added.

    You use is not the correct syntax to remove the element of the personStats object.

    Get the element that corresponds to the name of the person the subject form;

    Event.Value = personStats [this.getField("PersonName1").valueAsString];

  • Get NaN with the Javascript variable

    Hi all

    I'm learning javascript and I'm having a problem. I can't use a variable in javascript correctly. The function below shows the problem. When I use the variable vRow gets my value, however when I try to use the link_line variable I get NaN in my field in a table (f37).

    Can someone identify the problem here? I tried everything, including parseInt, parseFloat conversions, but I can't understand what is wrong.

    Thanks for your help!
    <script>
    function f_ValidateLinkLine(pThis) {
        
       // The row in the table
     var vRow = pThis.id.substr(pThis.id.indexOf('_')+1);
    
      // A value entered by user in tabular form on this row
     var link_line = parseInt(html_GetElement('f20_'+vRow).value);
      
         // Set the value for f37
     
        // This works!
        html_GetElement('f37_'+vRow).value = parseFloat(html_GetElement('f01_'+vRow).value);
    
        // This puts NaN in my field! Why?
        html_GetElement('f37_'+vRow).value = parseFloat(html_GetElement('f01_'+link_line).value);
     
        } // End ValidateLinkLine
    
    </script>
    Published by: blue72TA on August 12, 2011 12:09 AM

    Hmmm... Is it possible that it's to do with the naming convention for item IDs tabular?

    I have the feeling that the reason why your call to

    alert( html_GetElement('f01_'+link_line).value )
    

    Returns "undefined" is perhaps because the item you are looking for is actually called something like:

    F01_0001
    

    So if you simply concatenate F01_1, of course I don't think he'll find something with this specific ID (even if from a semantic point of view, that's what you intend). Try the same test, except F01_0001 hardcode in his place, I think you'll probably have a more fruitful response.

  • Artifacts when moving object with the help of the arrow keys.

    Hi all

    hope this is the right place to post this question.

    I want to write simple arkanoid game in Flash (AC3). I managed to write code that moves my paddle with the arrow keys. The code looks like this:

    function OnNewFrame(event:Event):void
    { 
        if (input.IsLeftHeld)
        {
            if (paddle.x > 0)
            {
                paddle.x -= 10;
            }
        }
        else
        if (input.IsRightHeld)
        {
            if (paddle.x < stage.stageWidth - paddle.width)
            {
                paddle.x += 10;
            }
        }
    }
    

    It works, but the result is ugly. The animation is not smooth, there are moments when the paddle stops for a moment. Also when the speed of translation is high (this is 10) you can see that paddle flashes at the ends, it resembles the unique problem of buffering. You can see both of these effects here: http://www.flash-game-design.com/flash-tutorials/movOb.html , identified flicker is less visible due to the amount of small translation.

    How to solve this problem? How can I enable double buffering (or maybe it is enabled by default)?  Any help will be appreciated.

    PS Sorry for the bad English

    Hello! I think you went backwards... First - in order to achieve the best visual transitions - you will not use travel speed at all. Second - you must pay attention to the establishment of the frame rate of the Flash document. Vivid games usually run at 60 frames per second. So I made a sample for you. Try it, it: http://cdn.dmldevelopment.com/plugins/tests/paddle/paddle.html . You can use arrow keys plus a key space to see how smooth the transition is. And you can download the source code here: https://rapidshare.com/files/3779443821/paddle.zip . Please let me know if I helped you. See you soon!

Maybe you are looking for

  • Skype causes the freezing of the screen when I make a call.

    I read so many subjects of this, everything tried and Skype still causes my screen to freeze, resulting in a reboot when I try to call someone or vice versa. I use the latest version of Skype. I tried different versions, reinstall several times and I

  • import messages in OE6 problem

    I can't import messages/issues of identity. I lost some files/folders this morning (don't know not how they were deleted, I think that the now missing folder has been selected by mistake and pulled to another folder of Outlook Express existing) so I'

  • Windows (8) could not complete the installation.

    I just bought a new HP2000 today. I get home and start of implementation. At the end of the process, when it * must * be showing me the office (or whatevert, they call the thing in W8), I get this error message. I click 'OK' and it reboots and starts

  • DRIVER AUDIO HELP!

    I accidentally deleted (windows xp professional sp2) microsoft high definition audio driver package kb888111 from my computer, where can I download it? If anyone can, please help me! I would really appreciate it! Thank you very much!

  • BBM on Alpha Dev channel C

    Hi all I had a problem to install channel BBM in my Dev Aplha C. Just curious, that dev Alpha C power to install BBM channel? or not? If allowed, how can I install it. coz I already got the keycode and also the keycodeloader file. but it does not wor