Register

If this is your first visit, please click the Sign Up now button to begin the process of creating your account so you can begin posting on our forums! The Sign Up process will only take up about a minute of two of your time.

Results 1 to 3 of 3
  1. #1
    Senior Member
    Join Date
    Mar 2002
    Location
    Alabama sans the damn flag
    Posts
    263
    Member #
    38
    Code:
          PatData_Array = PatHead_Text.split(PatHead_Delimiter);
         
          PatUser_Text = new String('PersonID');
          for (var i = 0; ((i<PatData_Array.length) & (PatData_Array[i]>'')); i++) {
              alert(PatData_Array[i]);
          }
    works fine.

    Code:
          PatData_Array = PatHead_Text.split(PatHead_Delimiter);
         
          PatUser_Text = new String('PersonID');
          for (var i = 0; ((i<PatData_Array.length) & (PatData_Array[i]<>PatUser_Text)); i++) {
              alert(PatData_Array[i]);
          }
    gives the error.

    I tried declaring PatUser_text with var ... and with
    PatUser_Text = new String('PersonID'); same thing

    I tried using 'PersonID' instead of the variable ... same thing

    I can't see where I'm doing anything wrong.
    DerFarm
    I talk to squirrels.
    Squirrels Answer.

  2.  

  3. #2
    Senior Member filburt1's Avatar
    Join Date
    Jul 2002
    Location
    Maryland, US
    Posts
    11,774
    Member #
    3
    Liked
    21 times
    Not sure if these are the problems, but & is a bitwise and (use && instead) and <> in Javascript (does not equal) is !=.
    filburt1, Web Design Forums.net founder
    Site of the Month contest: submit your site or vote for the winner!

  4. #3
    Senior Member
    Join Date
    Mar 2002
    Location
    Alabama sans the damn flag
    Posts
    263
    Member #
    38
    That was it. I suspect that the <> was the killer, the bitwise comparision would have been alright, I think ....
    DerFarm
    I talk to squirrels.
    Squirrels Answer.


Remove Ads

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
All times are GMT -6. The time now is 08:56 AM.
Powered by vBulletin® Version 4.2.3
Copyright © 2019 vBulletin Solutions, Inc. All rights reserved.
vBulletin Skin By: PurevB.com