5,237 Posted Topics
Re: Read the manual page for 'crontab' | |
Re: I look forward to a time when all overt expression of religion and idolatry is treated for what it is, namely a mental illness. I also regard teaching children about religion as institutionalised child abuse. Religions would die out within a generation or two if it were not for the … | |
Re: > for(i=0;i<81;i++) loadfile>>save[i]; What is save ? [code] buf=(char *)GlobalAlloc(GPTR,len+5); GetDlgItemText(hwndsl, IDC_SAVELOAD, buf, len + 5); } switch(option) { case 's': if(buf==NULL) { MessageBox(hwndsl,"Please enter the file name!","Request:",MB_OK); goto endmark; } SAVE(buf); endmark:[/code] 1. You ignore return results 2. You use a pointer, THEN later on test it for NULL … | |
Re: Not only does the post lack code tags, I see void main and various usage of ) and ; mangled into smilies. Oh well, better luck next time. ![]() | |
| |
Re: The easiest way for a single file is to type [INLINECODE]cl prog.c[/INLINECODE] at the command prompt. | |
Re: > I'm looking for a good program writing tools C++ VI VI VI - the editor of the beast :D | |
Re: That's about as useful as the Campaign for the Removal of Acronyms in Programming. | |
Re: Remember these? Last edited by Ancient Dragon : 1 Day Ago at 22:05. Reason: add code tags Last edited by Ancient Dragon : 1 Day Ago at 05:02. Reason: add code tags -- please start using them Or what about this [url]http://www.daniweb.com/forums/announcement118-3.html[/url] Not to mention the watermark at the back … | |
Re: Well the 5 threads at the top of the forum whose titles begin "Read Me: " would be a good place to start. > what is the latest version of C++? There is a single standard, released in 1998, generally referred to as C++98. But that only describes what a … | |
Re: Well that is basically how you do it. Post what you tried, provide it with an example input matrix, print the result and tell us how that differs from what you expected to see. | |
Re: I see void main() and a lack of code tags. No doubt both have been mentioned before, obviously with no impression on you. | |
Re: No there isn't (at least not on any compilers I'm aware of). If you want to share information, use the standard parameter passing mechanisms. This is all you get [url]http://msdn2.microsoft.com/en-us/library/d9x1s805(vs.71).aspx[/url] | |
Re: Tell us how many netiquette rules you've broken. [url]http://www.catb.org/~esr/faqs/smart-questions.html[/url] | |
Re: [url]http://www.daniweb.com/forums/announcement8-3.html[/url] In a survey of Daniweb, this link appeared 99.9% of the time - I wonder why? Probably because all the noobs are impatient dolts who can't wait to get their post onto the web, and don't give a rats ass what the resulting mess looks like. News flash - … | |
Re: > to copy over the mSEED_data.subframe to the mSEED_record.frames[x] . I use memcpy Except your code is copying the other way... Besides, the final sizeof should have been [INLINECODE]sizeof(compressed_frame)[/INLINECODE] to maximise the benefit of using the typedef. > [INLINECODE]int subframe[MAXWORDSPERFRAME];[/INLINECODE] Saying [INLINECODE]compressed_frame subframe;[/INLINECODE] would have been more in keeping with … | |
Re: > I need help for this C Program very urgent [url]http://www.catb.org/~esr/faqs/smart-questions.html#urgent[/url] Urgency is your problem, not mine. > please find the attachment below [url]http://www.catb.org/~esr/faqs/smart-questions.html#formats[/url] I'm not interested in even risking downloading a non-portable file format which is prone to all sorts of virus infections. | |
Re: Perhaps start by saying which OS you're using. Then perhaps a search. [url]http://clusty.com/search?query=USB+insert+notification+event&sourceid=Mozilla-search[/url] Basically, the OS generates the initial event, and then you hook into that in some way to do what you want to do. | |
Re: Can you for example open a text file and print the contents of the text file to the screen? If you can do that much, then you're prepared for the next step. If you can't, then we need to clear that bit up for you before progressing with the searching … | |
Re: How many times did you press "compile" before posting it here? My guess is that you've tried to write the whole lot at once, pressed compile and got several hundred errors, panicked and posted the whole mess here for someone else to sort out. Or you just kept typing even … | |
Re: [url]http://www.daniweb.com/forums/announcement8-2.html[/url] Sure, but first you need to - make an attempt - post what you tried - ask a proper question about what is going wrong, or what to do next. But if you insist on cheating your way through college, then perhaps this will help. [url]http://clusty.com/search?query=tic+tac+toe+source+code&sourceid=Mozilla-search[/url] Assuming you don't … | |
Re: > //Creating programe to store names & display names with max of [COLOR="Red"]30[/COLOR] characters [INLINECODE]char name[6][[COLOR="Red"]20[/COLOR]];[/INLINECODE] There's the first problem. > #include <iostream.h> This is old-style C++. New C++ should use [INLINECODE]#include <iostream> using namespace std;[/INLINECODE] If your compiler doesn't like that, then you definitely need a newer compiler. > … | |
Re: I guess it's because of bugs in your code. But since we can't see the code, I guess you'll either have to post it or figure it out for yourself. | |
Re: Here's a tip - press the preview button (go advanced) until you're sure you've got all the [B][co[b][/b]de][/code][/B] tags in the right place. Random attempts at sprinkling the various bits of tags around the place doesn't work. You can also edit your own posts as well (within a few minutes … | |
Re: What you really have is this [code] if(inCrem == tgPlacers.size()) [COLOR="Red"] { /* The ; at the end of your if is a NO-OP */ } [/COLOR] { Anything = false; break; } [/code] | |
Re: Given your previous posts, I'd say it's down to bugs in your code. All things being equal, what you describe might be unwise for the reasons AD states, but it certainly shouldn't segfault. Convince yourself by writing a simple program consisting only of your large array, and a simple main() … | |
Re: Something wrong with search engines all of a sudden? [url]http://clusty.com/search?query=image+processing+algorithms&sourceid=Mozilla-search[/url] IMO, if you're incapable of doing your own research into image processing, you're not going to get very far once you find them. | |
Re: That's because there's no such thing as fork() or unistd.h on your average windows box. Win32 doesn't have anything like fork() as such, see the hoops [URL="http://www.cygwin.com/cygwin-ug-net/highlights.html"]cygwin[/URL] has to go through in order to emulate it (poorly). If you're doing the typical fork() followed immediately by exec(), then using [URL="http://msdn2.microsoft.com/en-us/library/ms682425.aspx"]createProcess[/URL] … | |
Re: For sure it is an overflow waiting to happen. You can't just invent sizes and hope that it will all work out, it won't. If you want to be sure that all your allocs are correct, then use this form. [INLINECODE]p = malloc ( num * sizeof *p );[/INLINECODE] where … | |
Re: Given a series of "else if", you only ever get the first one which evaluates the true. Any other later ones which also happen to be true are skipped. | |
Re: Because rand() isn't random at all perhaps? The default algorithm is very simple, something along the lines of [url]http://en.wikipedia.org/wiki/Linear_congruential_generator[/url] The first few iterations are likely to exhibit a degree of predictability which one might not expect. See also [url]http://c-faq.com/lib/notveryrand.html[/url] | |
Re: Well you could start with this [url]http://www.catb.org/~esr/faqs/smart-questions.html#writewell[/url] Then scroll up a few lines to where all the sticky threads are, in particular the one called [URL="http://www.daniweb.com/forums/thread70096.html"]C++ Books[/URL] Though if you've never programming anything at all before, then C++ is a big jump. Be prepared for a good few months of … | |
Re: > %.10s%d sprintf() this to a temporary string first, then use printf("%60s") or whatever to print that result in the field width you've chosen. | |
Re: Your code is a catalogue of disasters! I'm amazed you've got this far to be honest. I'm sure not going to catch them all here, but rest assured this is like shooting fish in a barrel. [B]Buffer problems[/B] [INLINECODE] char * sYear = (char *) malloc(2); sYear = strncpy(sYear,sFileName+3,2);[/INLINECODE] 1. … | |
Re: Perhaps begin with a function called 'isVowel()', which returns true or false, depending on the type of letter passed to it. Then implement your own 'strcpy' like function, which makes use of isVowel() | |
Re: So pass two arrays to the function [code] void function( const int matrix[3][4], int result[3][4] ) [/code] So rather than trying to do something like [INLINECODE]result = function(mymat);[/INLINECODE] you do [INLINECODE]function(mymat,result);[/INLINECODE] | |
Re: Or you could use this to walk an entire sub-tree [url]http://www.linuxmanpages.com/man3/ftw.3.php[/url] | |
Re: > CreateHVFESection0(vpSec0); Following the call, vpSec0 will still be NULL. > vpSec0 = bitio_o_close(hSec0, nbytes); This does NOT update the variable passed as a parameter in the caller. It only updates the formal parameter copy of that variable. If you're really trying to return this result to the caller, then … | |
Re: Well the first step is to make sure you can read the file properly before trying to do anything with the data. If the file reading produces garbage, it doesn't matter how wonderful the rest of the code is, it will still be garbage. [code] #include <fstream> #include <iostream> using … | |
Re: It's that [URL="http://www.daniweb.com/forums/post409918-2.html"]deja vu[/URL] feeling all over again. History repeats itself, it has to, nobody listens. | |
Some people just don't get it. The water mark and the sticky thread just isn't cutting it, something more drastic is needed, like say 3 strikes and you're banned for 24 hours. Then there are a persistent minority with 10+ posts who still don't get it. And why would they … | |
Re: Doesn't that rather depend on your operating system? And if that OS is a Unix/Linux type system, the current setting of your umask. | |
Re: Because dir.h is a fossil DOS header file, and your compiler is something more modern perhaps. You should be using [URL="http://msdn2.microsoft.com/en-us/library/Aa364418.aspx"]this API[/URL] and related functions for getting directory information in a win32 environment. | |
Re: Remember this? [url]http://www.daniweb.com/forums/thread84431.html[/url] Last edited by Ancient Dragon : 18 Hours Ago at 03:48. Reason: add code tags and disabled smiles in the text Last edited by WaltP : 13 Hours Ago at 08:10. Reason: Added CODE tags -- you actually typed right over how to use them when you … | |
Re: Read this [url]http://www.daniweb.com/forums/announcement125-3.html[/url] Then edit your post for readability. | |
Re: > I need all the help i can get for this projct Then what? 6 months later you're back asking for help on your first trivial work assignment? Because you got a job you didn't deserve on the back of the "aced" final year project. Final year projects are there … | |
Re: [URL]http://www.daniweb.com/forums/announcement118-3.html[/URL] | |
Re: Is this the first function called from main()? Or is there a lot of other stuff which could have screwed up, and here is where you get to notice? Try the code in isolation (a simple main, this function, and not much else). Does it work? If so, then the … | |
Re: > It says to add #include "stdafx.h" when i do that i get this error. Lemme guess, you added this to stdafx.h as well. "Hello, recursive file inclusion, WTF happened to all my disk space" |
The End.