Forum: C++ Nov 10th, 2006 |
| Replies: 14 Views: 2,645 Hey,
In your printshippos function, you declare checkFlag at the top of that cpp file. When you initialize it like that w/o any number, it is either an unknown number, or in most cases, 0. The... |
Forum: C++ Nov 10th, 2006 |
| Replies: 14 Views: 2,645 hey, would you mind posting your code of sending me your code? I'd like to see your working code just so I can study it. |
Forum: C++ Nov 9th, 2006 |
| Replies: 14 Views: 2,645 I noticed too that you declare shippos inside an if block { } and try to refer to it in the next if statement, which is in a different block of code. That is probably why it prints out as 0+228... |
Forum: C++ Nov 9th, 2006 |
| Replies: 14 Views: 2,645 Here is a link that might help you.
http://www.functionx.com/managedcpp/keywords/static.htm |
Forum: C++ Nov 9th, 2006 |
| Replies: 14 Views: 2,645 I think the problem is because when you declare a variable static it affects the lifetime of it. You declare it inside the If brackets { }, so it will be destroyed at the end of the if statement.... |