Here is the loop code:
When I breakpoint it, it goes to the i = 1 then the args.Length and then it just goes to the code under the loop?? Why?Code:for(int i = 1; i == args.Length;i++) { }
Here is the loop code:
When I breakpoint it, it goes to the i = 1 then the args.Length and then it just goes to the code under the loop?? Why?Code:for(int i = 1; i == args.Length;i++) { }
The loop will execute as long as the second expression (i == args.Length) evaluates to true.
Is this the case? Does args.Length return 1? Even if that was the case, it would only execute the loop once.
---My Flickr photo (mostly screenshots these days!) stream. Have a look!
![]()
Rate posts that helped you. I do not reply to PM's with coding questions.
How to Get Your Questions Answered
TCP client/server connection | Retrieving the EventHandler for any Event by code.
Check out the work in progress: Vortex - C++ 3D Game engine for windows and linux - (Development blog - Leave a comment!)
args.Lenght return 8 when I use breakpoints....
I assume you intend to iterate over the contents of args?
Code:for(int i = 0; i < args.Length; i++) { }
---My Flickr photo (mostly screenshots these days!) stream. Have a look!
![]()
Rate posts that helped you. I do not reply to PM's with coding questions.
How to Get Your Questions Answered
TCP client/server connection | Retrieving the EventHandler for any Event by code.
Check out the work in progress: Vortex - C++ 3D Game engine for windows and linux - (Development blog - Leave a comment!)
Now it works
I had used == instead of <.
Oh and I want to start from 1.
Thx for helping :P