4 Replies Latest reply: Jun 27, 2009 12:58 PM by 807588 RSS

    Problems with boolean...

    794044
      Hello,

      This is my problem:
                System.out.println(vakGevuld);
                if(vakGevuld=true)
                {
                     System.out.println(vakGevuld);
                     vakGevuld = false;
                     System.out.println(vakGevuld);
                     System.out.println("Is here the error? :(");
                     checkSpeler();
                }
      The first line says false, however my if still reads it as true and continues, and my debug so says:

      False
      True
      False...

      So why does my if(vakGevuld=true) think it's true while it's False?

      Thanks

      Edited by: The_Pointer on Jun 27, 2009 9:20 AM

      Edited by: The_Pointer on Jun 27, 2009 9:23 AM