Forum: C Oct 14th, 2009 |
| Replies: 4 Views: 348 Even more peculiar is have the E in 'ecake' disappears, what a mystery! :icon_lol: |
Forum: C Oct 13th, 2009 |
| Replies: 2 Views: 316 One, you have to specify to the linker that it's a windowed application.
Then you get the window handle, and with ShowWindow(), in the second parameter use SW_HIDE.
edit:
You'll probably also... |
Forum: C Oct 13th, 2009 |
| Replies: 6 Views: 287 I think first you need to simplify, so as that you can clearly follow and read it. For instance: that whole if(hexstring[i+2]==10 through 15) and then ending it with a redundantly unnecessary else... |
Forum: C Oct 13th, 2009 |
| Replies: 2 Views: 224 You'll need to learn assembly, if you want get to the raw hardware level of programming. Assembly is easily integrated into most C compilers.
Truthfully, I think you have much more to learn about... |
Forum: C Aug 30th, 2009 |
| Replies: 2 Views: 352 Actually I have a simple library I wrote for executing machine code off an executable page.
The basis of it all for single page without a pointer(to arguments pushed on the stack) is simply:
... |
Forum: C Aug 6th, 2009 |
| Replies: 13 Views: 747 The only times it should ever be used are of the most rarest situations.
So don't get any ideals about using in substitution of well planned logic. |
Forum: C Aug 4th, 2009 |
| Replies: 2 Views: 245 All I can find:
http://msdn.microsoft.com/en-us/library/ms713752(VS.85).aspx
Maybe this?:
http://msdn.microsoft.com/en-us/library/dd370859(VS.85).aspx |
Forum: C Aug 4th, 2009 |
| Replies: 15 Views: 882 Don't use goto, try a function. You already have a switch in an if statement, don't make it any more complex.
Avoid fflush() and look into a replacement of scanf() |
Forum: C Aug 1st, 2009 |
| Replies: 5 Views: 408 Why are you talking like this? |
Forum: C Aug 1st, 2009 |
| Replies: 5 Views: 363 Perhaps simplify:
for(int i = 0; i < 100; i++)
Works out as:
int i = 0;
while(i < 100)
i++; |
Forum: C Jul 21st, 2009 |
| Replies: 7 Views: 774 It's dramatically difficult to diagnose non-existent code. You may want to provide us with some to solve the first-most issue. |
Forum: C Jul 20th, 2009 |
| Replies: 5 Views: 282 main() might not be a traditional function, just the starting address of the program, that as well might have no return. All implementation dependent, and only in more rare cases obviously. |
Forum: C Jul 10th, 2009 |
| Replies: 5 Views: 488 Yes, go with adatapost's advice and get a current compiler.
If you need basic graphics, try out the SDL library. Easy and can do things far beyond what "graphics.h" could ever do. |
Forum: C Jul 3rd, 2009 |
| Replies: 8 Views: 568 Download Code::Blocks, and keep these sites bookmarked:
http://www.cprogramming.com/tutorial.html#ctutorial
http://www.cplusplus.com/reference/clibrary/
http://www.cppreference.com/wiki/... |
Forum: C Jun 29th, 2009 |
| Replies: 4 Views: 526 When you set a pointer and don't always use every "point" in it(especially while dealing with user input), you need memset() to set a default value. |
Forum: C Jun 24th, 2009 |
| Replies: 3 Views: 281 conio.h isn't used, and should never be.
Macros used like that are dangerous.
It's: int main() { return(0); } |
Forum: C May 30th, 2009 |
| Replies: 5 Views: 1,123 Referring back several pages on the forum:
http://www.daniweb.com/forums/thread187421.html |
Forum: C May 28th, 2009 |
| Replies: 0 Views: 1,096 Two version that do exactly the same thing! |
Forum: C May 27th, 2009 |
| Replies: 0 Views: 622 |
Forum: C May 27th, 2009 |
| Replies: 1 Views: 1,197 Cheap, dirty code for Windows and *nix. |
Forum: C May 25th, 2009 |
| Replies: 8 Views: 1,684 Or just use XOR 32 to swap the values of a valid range. Ta-da... |
Forum: C May 14th, 2009 |
| Replies: 1 Views: 378 You mean those format things: http://www.cplusplus.com/reference/clibrary/cstdio/printf/ |
Forum: C May 13th, 2009 |
| Replies: 9 Views: 1,010 It doesn't work because you're using nonstandard code written for ancient compilers.
conio.h should be removed from your code.
main() by standard requires a return value(except in very rare... |
Forum: C May 8th, 2009 |
| Replies: 33 Views: 68,824 When will this be locked, or better yet - deleted! |
Forum: C May 7th, 2009 |
| Replies: 5 Views: 459 |
Forum: C May 5th, 2009 |
| Replies: 3 Views: 227 Try _sleep(1);, you could also add this to a low priority thread that the app waits for to die.
edit:
Also printf() will interrupt the whole process, so only use it on so many increments of time. |
Forum: C May 1st, 2009 |
| Replies: 5 Views: 1,176 What is with all the Turbo C++ references?!! That compiler is a non-standard relic from another millennial! It's useless! |
Forum: C Apr 30th, 2009 |
| Replies: 5 Views: 846 Take note that, main() must return zero by standard, and conio.h doesn't exist on most compilers. |
Forum: C Apr 27th, 2009 |
| Replies: 5 Views: 1,176 Actually this question has more to do with what OS(unless its, doubtfully, hardware specific).
Just use something like OpenGL or SDL, for graphics. |
Forum: C Apr 24th, 2009 |
| Replies: 57 Views: 2,422 You could simplify your whole Keyboard() function to a few if else conditions. |
Forum: C Apr 22nd, 2009 |
| Replies: 7 Views: 880 You mean like const volatile type variblename;, or the difference between the two? |
Forum: C Apr 20th, 2009 |
| Replies: 9 Views: 1,116 marco93 is just a bot that's managed to strangely survive for so long. |
Forum: C Apr 19th, 2009 |
| Replies: 9 Views: 1,116 I don't think there's a standard way of doing it.
There was something in the Intel manual: http://download.intel.com/design/processor/manuals/253668.pdf
And here's a project you might want to look... |
Forum: C Apr 18th, 2009 |
| Replies: 14 Views: 4,150 Why did you revive a dead thread? You did not use code tags(site rule) leaving it unformatted, and we have section for posting code snippets.
Why is there .h's after your C++ headers? Why is there... |
Forum: C Apr 16th, 2009 |
| Replies: 27 Views: 1,772 It's so non-standard the kid would get in trouble anyway. |
Forum: C Apr 16th, 2009 |
| Replies: 4 Views: 368 Okay what platform and compiler?... It's generally nothing, more than a single line in the inline assembler, unless you're executing it off the heap. |
Forum: C Apr 10th, 2009 |
| Replies: 11 Views: 700 Prototypes don't go inside other functions. |
Forum: C Apr 7th, 2009 |
| Replies: 6 Views: 813 The linker doesn't need to know a thing about headers, that's all taken care of long before it gets to that point. A linker should just take your freshly compiled objects and put them together, in... |
Forum: C Apr 7th, 2009 |
| Replies: 1 Views: 236 |
Forum: C Mar 30th, 2009 |
| Replies: 5 Views: 313 If the file is NULL, then why are you still using it afterwords? Perhaps you should have one function to load, and one to save.
You aren't closing the file pointer after you're finished. |