|
Can someone plz try it.. i'm serious it has no errors.. i can't even see any by eye.. but it skips some..
|
|
|
|
|
Cbadboy wrote: i'm serious it has no errors...
Well it obviously does or you would not be asking for help. Use the debugger.
"Love people and use things, not love things and use people." - Unknown
"The brick walls are there for a reason...to stop the people who don't want it badly enough." - Randy Pausch
|
|
|
|
|
Debugger isn't helping what do u think I've been using this whole time before I posted question.. it just breakpoints on 1 line.. i see everything inside sscan the tokens and such... I even see the npcId value but it doesnt set up inside the npcId datatype.. which remains zero.................................
|
|
|
|
|
Cbadboy wrote: Debugger isn't helping what do u think I've been using this whole time before I posted question...
How could I possibly know the answer to that since you never mentioned what you tried?
As someone that helps on this board FOR FREE AND IN MY SPARE TIME, my assumptions are based solely on the information, or lack thereof, that you provide. If you want us to know something, tell us.
"Love people and use things, not love things and use people." - Unknown
"The brick walls are there for a reason...to stop the people who don't want it badly enough." - Randy Pausch
|
|
|
|
|
Cbadboy wrote: moveRange1.x: 0 (wrong for again no reason as the format pattern matches)
If you replaced the 0 in line to some other number, what value would moveRange1.x have?
Cbadboy wrote: So whats wrong really
How about coords.x having a value of 3412 instead of 3419?
What does sscanf() return?
"Love people and use things, not love things and use people." - Unknown
"The brick walls are there for a reason...to stop the people who don't want it badly enough." - Randy Pausch
|
|
|
|
|
6 and problem is solved..
instead of %d i had to use %hd
for some reason int's in structs are different datatype yup just a lesson i learned
|
|
|
|
|
Cbadboy wrote: instead of %d i had to use %hd
Which means you had a short int .
Cbadboy wrote: for some reason int's in structs are different datatype
No such difference exists.
"Love people and use things, not love things and use people." - Unknown
"The brick walls are there for a reason...to stop the people who don't want it badly enough." - Randy Pausch
|
|
|
|
|
Hi All
I have problem to store a string type values in array.Simple i did it but my problem is how can i define a size of array,when i don't know how many data is came in array.I am stroing data in array at the run time.And don't want to fixed the size of array.Plz help me
|
|
|
|
|
Try the CArray class in the MFC and if you dont use MFC, check the vector class.
|
|
|
|
|
Nprog wrote: to store a string type values in array
Use CStringArray
|
|
|
|
|
You can also approach in STL way with std::string/std::wstring with containers like vectors, deque, list etc...
e.g vector<string> arrString; defines a string array in STL way. you can also approach other containers based on your use. Probably a vector will do.
-Sarath.
"Great hopes make everything great possible" - Benjamin Franklin
|
|
|
|
|
|
I was wandering if you guys know of any resources on web browser development
Plasma Steel Games | Web Administrator
FlashCoded.net | Web Administrator
|
|
|
|
|
Huh?
Neither Google nor CodeProject's search engines are working right now??
|
|
|
|
|
Plasma Steel Games wrote: I was wandering
Stop wandering and start searching in Google.
Many are stubborn in pursuit of the path they have chosen, few in pursuit of the goal - Friedrich Nietzsche
.·´¯`·->Rajesh<-·´¯`·.
[Microsoft MVP - Visual C++]
|
|
|
|
|
|
Do you want to make it youeself or you want to use of open source codes? and whats your language c++?
|
|
|
|
|
I have a DAG (Direct Acyclic Graph) file and when directly open in C++, shows following:
processors 16;
comp 287 comma 129 commb 2430450;
taches 382;
10000,0 ;
10000,0:100;
10000,0:101;
....
....
....
Can any1 plz tell me how to open this file in C++ because after opening I need to work on the values it has. I know how to open a .txt file but how can I open this kind of file?
nOmI
|
|
|
|
|
Hi,
I'm maintaining an app that when I exit the application I get row after row of this:
f:\dd\vctools\vc7libs\ship\atlmfc\src\mfc\strcore.cpp(141) : {33671} normal block at 0x02A2EA78, 21 bytes long.<br />
Data: <<N¤x > 3C 4E A4 78 04 00 00 00 04 00 00 00 01 00 00 00 <br />
d:\development\AppName\ProjectName\SomeFile.cpp(5716) : {33670} client block at 0x03897278, subtype c0, 2118 bytes long.<br />
a CNSFlexPropertyPage object at $03897278, 2118 bytes long<br />
Object dump complete.<br />
The program '[0xC90] AppName.exe: Native' has exited with code 0 (0x0).
Are these memory leaks? My fear is that they are memory leaks.
Thanks!
|
|
|
|
|
Like2Byte wrote: Are these memory leaks? My fear is that they are memory leaks.
Yes.
On the plus side, the dump tells you what line of code
did the allocation that wasn't freed...way easier than
trying to find it blindly.
Mark Salsbery
Microsoft MVP - Visual C++
|
|
|
|
|
Thank you very much for your swift response.
In the interim, I located this magic gem:
Detected memory leaks!
Dumping objects ->
my list ensues. Subtracting the 6900 lines of front matter preceding the memory leak dump I'm left with 39011 lines of memory leak reports(or 19505 individual memory leak detections).
That being said, I think I'm going to be sick.
|
|
|
|
|
Like2Byte wrote: I'm left with 39011 lines of memory leak reports(or 19505 individual memory leak detections).
Ouch.
Mark Salsbery
Microsoft MVP - Visual C++
|
|
|
|
|
|
Thank you for pointing this out to me. I will give this try. I haven't read the entire link in detail but it looks very promising.
I've looked through a few of the memory leaks and some are as simple as
double* d = new double[nRecords*MAX_RECS];
...stuff
delete d; // where it should be delete[] d;
|
|
|
|
|