Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations gkittelson on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

a Win API function failed

Status
Not open for further replies.

finnmike

Programmer
Oct 17, 2001
50
DE
Dear guys (all sexes),

I seem to get error messages containing "A WInApi function failed" randomly when running my app.

What happens is, that I run Netscape 7.0 and maybe one or 2 MS apps parrallel to the BCB5 on W98.

Am I out of memory already and BCB5 doesn't tell me this?
And the most important question:

HOW DO I CATCH/GEt RID OF these errormessages?

Is it the windows function "NoErrors()"?

my application is now 2.85 Megs big, wasn't there a magic line not to cross?
I would need to run the app more than 3 times parallel, but in the best case
(no other prog running) I manage 3 instances.

Memory sleuth (former from Turbopower) says all is ok.

Do I need toi run the CodeGurad, and if how to interprete his mesages?

I have 1230 warnings when compiling, and I can only run the program when it is compiled in debug mode.

release mode compiling gives out errors, does anybody know where to look, what to analyze to make it run in release mode?

I normally manage to get around these effects, but what if I start to use more
components (Ipro/ former turbopower)?

Best regards,

Michael




 
"WinAPI function failed" is probably reported by some component in your app. (if you are not using WinAPI in your code) Which one is hard to tell...
Size of your executable is not the problem (I managed to run a 50MB app), but you should first try to get rid of those warnings. 1000s of them is not a good sign!
 
Your application is 2.85 megs? I would say that's your problem, because I had the same problem running an older compiler of Borland also. It hit me JUST at that spot with errors after compiling. In fact, all I did was add a boolean variable definition to the .h file, and compiled and ran, and BOOM, no good. Took the boolean back out, and it worked. All I can assume is that there are application space maximums on older Borland compilers, although I've never seen it in writing (would probably be a bug). Also note that my executable was so large because I had embedded bitmaps in it that were pretty big. I removed them and added all the booleans I wanted. :) Try and reduce your executable size and see if that helps.

Good luck,
Chris
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top