Forum: C++ Jun 27th, 2006 |
| Replies: 9 Views: 3,451 A valid question. The reason is this is data that USED to be in the database and was 'archived' off. |
Forum: C++ Jun 27th, 2006 |
| Replies: 9 Views: 3,451 So here's what I'm trying to do. Basically, I have a huge text file of strings which are delimited by a delimiter. I would like to read each string separately based on the delimiter. Note that each... |
Forum: C Jun 17th, 2006 |
| Replies: 8 Views: 2,606 I tried #1, still got 0.0.0.0 with it.. As far as #2, the issue is that I want to know what machine it is, so I don't know what to ping (and in any case, there's no need for me to ping it, since if... |
Forum: C Jun 16th, 2006 |
| Replies: 8 Views: 2,606 jim,
I'm a bit confused. If the client attempts to do a 'bind', won't it get an error that it's already in use? |
Forum: C++ May 14th, 2006 |
| Replies: 4 Views: 10,465 Assuming you won't in fact attempt to change 'crap' inside the 'bull' function, simply change the above to:
void bull( const char[] )
and
void bull( const char crap[] )
{
std::cout <<... |
Forum: C++ Apr 20th, 2006 |
| Replies: 10 Views: 3,623 That works, unfortunately, I don't want it to be a static function as I want it to use the instance of the class that I'm working in. |
Forum: C++ Apr 19th, 2006 |
| Replies: 10 Views: 3,623 Say what Dr. Dave?
I had trouble following your other thread too. guess I'm biting off more than I can chew. |
Forum: C++ Apr 19th, 2006 |
| Replies: 10 Views: 3,623 Dave,
Don't lose sleep over it. But if you're up anyway, yes please find the other thread ;)
WB |
Forum: C++ Apr 19th, 2006 |
| Replies: 10 Views: 3,623 Dave,
I was looking at that - went over my head. Is there an easy answer to my particular example? Part of the problem seems to be that I'm INSIDE my class when I'm trying to pass another member... |
Forum: C++ Apr 18th, 2006 |
| Replies: 10 Views: 3,623 So I'm trying to learn how to use function pointers (ie to pass the address of a function to another function to execute it - like a call back). I have it working when I use it as follows:
... |
Forum: C Apr 14th, 2006 |
| Replies: 2 Views: 1,356 Show us the code where you are requesting and accepting the string to begin with, then we'll show you how to modify it for the error checking. |
Forum: C Apr 13th, 2006 |
| Replies: 3 Views: 9,885 if x is 6 and y is 2, then the result is 0. |
Forum: C Mar 17th, 2006 |
| Replies: 3 Views: 6,371 If you want to make sure there are no numbers in a string, you can do a find_first_of( "01234567890"). If it equals anything other than string::npos, it's got a number in there. |
Forum: C Mar 13th, 2006 |
| Replies: 4 Views: 1,367 I guess the main question I have is how to define a variable that is not shared among threads inside a function that is used by a thread... |
Forum: C Mar 13th, 2006 |
| Replies: 4 Views: 1,367 I figured out a way to do it, just not sure if it's the right way. Let me know what you guys think:
Temp.cpp
extern "C"
{
#include "pthread.h"
#include "Thread.h"
}
#include <iostream>... |
Forum: C Mar 13th, 2006 |
| Replies: 4 Views: 1,367 I modified Thread.h to add the pthread_self() which shows which thread id it has...
#include "stdio.h"
#include "Temp.h"
pthread_mutex_t ilock;
void * myTest(void * arg)
{
char * test =... |
Forum: C Mar 13th, 2006 |
| Replies: 4 Views: 1,367 Hi Guys,
So I'm trying to experiment with threads, though I'm running into some problems. Basically I'm trying to create multiple threads, where each thread is passed a different set of data. In... |
Forum: C++ Nov 16th, 2005 |
| Replies: 7 Views: 59,011 Since it's in milliseconds, you might want to do something like 5000 to notice it. In unix, it's lowercase sleep, and it's in seconds.. |
Forum: C++ Nov 3rd, 2005 |
| Replies: 9 Views: 1,723 Also, shouldn't you be using the p in your function? (Rather than calling static methods, you would want to use the information stored in the Person object p). (for example p.getName() ) |
Forum: C Oct 23rd, 2005 |
| Replies: 3 Views: 2,271 Yes, just look at the other members of the tm struct. |
Forum: C++ Jun 3rd, 2005 |
| Replies: 28 Views: 44,109 Basically, the only way to do this is what narue suggested and pass in the actual size as a parameter to the function. Either that, or use an STL collection, and use .size() |