Jump to content

rogerg

Members
  • Content Count

    6
  • Joined

  • Last visited

Community Reputation

0 Neutral

About rogerg

  • Rank
    Newbie
  1. ok, any idea how to do a simple search function in JS that would work if I have an xml with <row><Heading0>a</Heading0><Heading1>b</Heading1><Heading2>c</Heading2><Heading3>d</Heading3><Heading4>e</Heading4><Heading5>f</Heading5><Heading6>g</Heading6></row>
  2. thank you very much not sure whether I tried it with alert - I tried to show the value directly in the form...I'm now managed to do that with the addition of a button in the form and the correct onclick command
  3. I could retrieve the matrixVal value, but only inside of the see function when I tested with an alert outside of the function, it didn't work... I can use the result within the function and do simple calculations like multiplications with it, but I haven't figured out how to do the factorial as I can't retrieve the matrixVal outside of my see function. Is there a way in JS to add a function within a function, i.e. could I add a factorial function like I tried within my see function? within the function I could do something like... L=(matrixVal*(matrixVal-1)*(matrixVal-2)*(matrixVal-3));docume
  4. thx for your answer what I'm trying to reuse is the result is the selected value so, if a user types insize 3line 1col 1 the value I want to reuse is 5, so what I have in function see ... document.getElementById('selected').value=myMatrix[y][z] How can I declare this value to reuse it at once for example to calculate and show it's factorial? I try doing so by adding a button factorial in the form with a onclick"function()", but when trying to declare the function I keep getting is not defined errors... do I have to declare a new variable already at the end of the see function or at the begin
  5. Hello, I would like to do some calculations in a predefined array. With the script below I can retrieve a number of the matrix.However, I want to reuse this number and do some calculations with it, for example calculate the factorial. But I don't now how I have to save the selected number and then to reuse it for further calculation. can you help me? Thx,Roger <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"><html xmlns="http://www.w3.org/1999/xhtml"> <head><title>MATRIX</title> </head><b
  6. Hi thereI am struggling with using JS to create a search on a xml file I have built.I have an xml file with over 1000 books listed and I wish to add a search option to it .As I imported an excel file with oxygen to create the xml, I have the xml written in the style<root> <row> <Heading0>English Literature</Heading0> <Heading1>Woolf</Heading1> <Heading2>Virginia</Heading2> <Heading3>To the lighthouse</Heading3> <Heading4>UK</Heading4> <Heading5>english</Heading5> <Heading6><
×
×
  • Create New...