|
what to write on those 2 blocks ?
|
|
|
|
|
Oh, just type in the kind of code that you want in the first box and your email address in the second box and voila! the code will be sent to you free of charge! It's such a life saver. 
|
|
|
|
|
thanx man DONE !
now waiting for their reply
|
|
|
|
|
No problem. Anytime you need code you can just go there instead!
|
|
|
|
|
You measure democracy by the freedom it gives its dissidents, not the freedom it gives its assimilated conformists.
|
|
|
|
|
|
Yuo need to get a clue, see here[^].
How, and BTW read the posting guidelines ("How to ask a question") at the top of this message board. What you are asking is similar as if I asked you to come clean my house, free of charge of course. I think you need to come back on earth, nobody's gonna write a full program for you free of charge.
|
|
|
|
|
This is my first thread! The thread is initialized during WM_CREATE.
However their are no errors during compilation, but when I run it the program breaks.
void Windows7ProgressThread(void *)
{
if (TotalBytesToDownload)
{
if (List.AnyFailed())
{
TaskbarProgress->SetProgressState(g_hWindow, TBPF_ERROR);
}
else
{
TaskbarProgress->SetProgressState(g_hWindow, TBPF_NORMAL);
}
TaskbarProgress->SetProgressValue(g_hWindow,50,100);
}
else
{
TaskbarProgress->SetProgressState(g_hWindow, TBPF_NOPROGRESS);
}
}
|
|
|
|
|
Fareed Rizkalla wrote: ...but when I run it the program breaks.
Really? Are we supposed to guess how?
"One man's wage rise is another man's price increase." - Harold Wilson
"Fireproof doesn't mean the fire will never come. It means when the fire comes that you will be able to withstand it." - Michael Simmons
"Man who follows car will be exhausted." - Confucius
|
|
|
|
|
The problem their are no errors, it breaks with error Access violation. :S
|
|
|
|
|
Even after I commented out what threading code I had written and the process.h header.
I run it and the same error is occurring over and over.
|
|
|
|
|
Fareed Rizkalla wrote: The problem their are no errors, it breaks with error ...
Really?
Fareed Rizkalla wrote: ...it breaks with error Access violation.
So single-step through the code until you find the offending line. If you think there are too many lines to wade through, read this thread on how to quickly narrow down a problem by removing unnecessary code.
"One man's wage rise is another man's price increase." - Harold Wilson
"Fireproof doesn't mean the fire will never come. It means when the fire comes that you will be able to withstand it." - Michael Simmons
"Man who follows car will be exhausted." - Confucius
|
|
|
|
|
It was because I removed the SUCCEEDED micro, but I can't believe the errors it gave me.
Thread exceptions and Access Violations.
I thought something went wrong with the project settings, cause it mentioned Multi-Threading.
Got WinMerge and started going over each line and started thinking what should be undone.
|
|
|
|
|
Fareed Rizkalla wrote: It was because I removed the SUCCEEDED micro, but I can't believe the errors it gave me.
The SUCCEEDED macro did not cause errors to your code. How could it:
#define SUCCEEDED(Status) ((HRESULT)(Status) >= 0)
"One man's wage rise is another man's price increase." - Harold Wilson
"Fireproof doesn't mean the fire will never come. It means when the fire comes that you will be able to withstand it." - Michael Simmons
"Man who follows car will be exhausted." - Confucius
|
|
|
|
|
Hello,
Can scanf be set to retain leading whitespaces in between words?
For example, if the string was " Hello everyone, how are you today? "
can scanf grab " Hello" " everyone," " how" " are" " you" " today?"
Thanks,
|
|
|
|
|
Only if you wrote your own parser. The other ideas that I mentioned to you would use the space as the delimiter.
"One man's wage rise is another man's price increase." - Harold Wilson
"Fireproof doesn't mean the fire will never come. It means when the fire comes that you will be able to withstand it." - Michael Simmons
"Man who follows car will be exhausted." - Confucius
|
|
|
|
|
|
You can do this to capture everything till the enter key is hit.
scanf("%[^\n]", sz);
|
|
|
|
|
|
Hi,
How can I advance the sscanf statement to read each word in the sentence? Right now my output is an endless loop of "This".
CString incoming_line="This is my example incoming line.";
CString string_out;
while (sscanf(incoming_line, "%s", string_out )==1)
{
cout<<string_out<<endl;
}
Thanks!
|
|
|
|
|
you could do something like this:
int offset = 0;
while (sscanf(incoming_line + offset, "%s", string_out )==1)
{
cout<<string_out<<endl;
offset += strlen(string_out);
}
|
|
|
|
|
Chris,
Thanks for your help.
I'm getting the following error when I use your suggestion.
Error 2 error C2666: 'ATL::CStringT<BaseType,StringTraits>::operator +' : 3 overloads have similar conversions
Any ideas?
Thanks,
|
|
|
|
|
oops. didn't see the CString there.
|
|
|
|
|
b-rad311 wrote: while (sscanf(incoming_line, "%s", string_out )==1)
You cannot use a CString object in this capacity.
"One man's wage rise is another man's price increase." - Harold Wilson
"Fireproof doesn't mean the fire will never come. It means when the fire comes that you will be able to withstand it." - Michael Simmons
"Man who follows car will be exhausted." - Confucius
|
|
|
|
|
Hi David,
Should I use "const char*" instead?
|
|
|
|