This week's book giveaway is in the Agile forum.
We're giving away four copies of Head First Agile and have Andrew Stellman & Jennifer Greene on-line!
See this thread for details.
Win a copy of Head First Agile this week in the Agile forum!
  • Post Reply Bookmark Topic Watch Topic
  • New Topic

List Iterator and If statement  RSS feed

 
Hosh Nasi
Ranch Hand
Posts: 44
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
In the code below I am trying to iterate through a list and call a method from the currently referenced object "If" its variable nRefId matches the nRefId of the calling object.



Thanks again guys. I am so close to the end now I can feel it.
 
Julian Kennedy
Ranch Hand
Posts: 823
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hosh Nasi,

You're not very clear on what your problem is. I take it that line doesn't compile? The capital "I" in "if" won't help. Failing that it looks fine. If that's not your problem can you be more specific?

Jules
 
Hosh Nasi
Ranch Hand
Posts: 44
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Yeah you nailed it.. I have been tirelessly working on this, and I am missing the little things..

Thanks.
 
marc weber
Sheriff
Posts: 11343
Java Mac Safari
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Originally posted by Hosh Nasi:
If(myObj.nRefId = nRefId)


Assignment is =. Logical comparison is ==.

 
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!