2 Replies Latest reply on Feb 22, 2013 7:36 AM by loufrank

    Cleaning an array of undefined data

    loufrank

      I have exhausted all my resources in trying to clean an array so I can use the information in my document. I have tried POP without any success.

       

      ===============

      Code:

      ===============

      var CHAR = new Array();

       

      for (j = 0; j < globalTabArray.length; j++){

      if( globalTabArray[j][2] != "Bill of Material" &&

          globalTabArray[j][2] != "Drawings" &&

          globalTabArray[j][2] != "Document Divider" &&

          globalTabArray[j][2] != "Technical Data"){

        

         console.println( globalTabArray[j][1]+1 + " == " + globalTabArray[j][2])

         CHAR[j] = globalTabArray[j][1];

      }}

       

       

      ===============

      Example output:

      ===============

      for (x = 0; x < CHAR.length; x++){

      console.println( CHAR[x])

      }

      undefined

      23

      undefined

      29

      undefined

      undefined

      undefined

      undefined

      undefined

      undefined

      undefined

      98

       

      Thanks for any help in this matter.