|
Hi all,
I have made a sdi application. In that i have made a worker thread in which i am taking out html code for websites. There can be thousands of websites whose html code i have to find out. I have made a for loop from which one by one thread is started accordingly. Now my problem is that the starting threads work fine but after some time all the pages start giving this page cannot be displayed.i tried to used semaphore(only 10 thread should start at a time) but it is also not working fine.
CSemaphore m_semaphore(10,10);
m_semaphore.Lock(60000);
m_semaphore.Unlock();
this code is written inside thread. But still same problem is coming. How to resolve this problem.
thanks in advance
|
|
|
|
|
All the threads should share a common semaphore object instead of
each of them having their own.
You can move your m_semaphore object outside of the thread proc
and it should work better.
Mark
Mark Salsbery
Microsoft MVP - Visual C++
|
|
|
|
|
can u help me guys?? i got stuck with one problem in my project. Actually when i open a Excel or any file in web browser the file download dialog will popup. i dont want that dialog, i directly want to open the Excel file in web browser. please if anybody have its code kindly send me ...i will be very obiliged to u .
-- modified at 9:11 Monday 20th August, 2007
|
|
|
|
|
Hi All,
is it possible to dISABLE a perticular row in a list control?
-- modified at 5:45 Saturday 18th August, 2007
|
|
|
|
|
Why hide a row when you can just delete it? When you populate the list, an idea might be to have a flag for each row checking if it's visible or not.
|
|
|
|
|
i mean i wnat to disable that row..
|
|
|
|
|
If you want to give a row the 'disabled' appearance, you will need to implement custom draw, and draw the row(s) as disabled.
Software Zen: delete this;
|
|
|
|
|
|
WhiteSky wrote: See An effective way to hide or show columns in list control dynamically[^] does any help?
Sure, assuming that rows are synonymous with columns.
"A good athlete is the result of a good and worthy opponent." - David Crow
"To have a respect for ourselves guides our morals; to have deference for others governs our manners." - Laurence Sterne
|
|
|
|
|
Is a function operator different from a functor?
|
|
|
|
|
that depends on who you're talking to.
|
|
|
|
|
I have come to know that many of US universities upload their video lectures on web servers. Do people here know of such sites?
|
|
|
|
|
The ones I know of only let you view if you are a student and require a login/password.
_____________________________________________
Flea Market! It's just like...it's just like...A MINI-MALL!
|
|
|
|
|
I have write a program for transmitting data to the EEPROM of my µC. I have a problem. The µC recieve only a few data and not all of em. The bauterate is setting by 9600 for µC and COM port. Wat I'm doing rong ?.
|
|
|
|
|
First, you need to make sure that the other communication parameters match as well. In addition to baud rate there's word size (5-8 bits per character), and parity (none, odd, or even).
Secondly, RS-232 defines a number of methods of doing flow control. This is a protocol for guaranteeing that the receiver has processed a character before the transmitter sends the next one. There are hardware and software protocols. The hardware protocols manipulate the 'modem' control lines to signal when the receiver is ready. The software protocols send specific characters from the receiver to the transmitter to start/stop the flow of data.
Software Zen: delete this;
|
|
|
|
|
Thanks, I try the software flow control now.
Jelle.
|
|
|
|
|
can a CHAR data type accept alphanumeric string? Practically this happens with my program? Please help is it is possible
|
|
|
|
|
A CHAR is a single character, therefore it cannot accept a string.
|
|
|
|
|
But CHAR arrays can.
CHAR MyArray[] = "Hello world";
CHAR* p = "Hello again";
Maxwell Chen
|
|
|
|
|
No it cant.Can you more explain about your program?
|
|
|
|
|
Hello gurus,
I have some linking problem with Visual Studio 2005 installed on an Windows XP Professional x64 Edition with Platform SDK for Windows Server 2003 R2 (march 2006).
I have the following linking errors:
1>xxx.obj : error LNK2019: unresolved external symbol __imp__wstat64i32 referenced in function xxx
1>xxx.obj : error LNK2019: unresolved external symbol __imp__stat64i32 referenced in function xxx
1>xxx.obj : error LNK2019: unresolved external symbol __imp__wfindfirst64i32 referenced in function xxx
1>xxx.obj : error LNK2019: unresolved external symbol __imp__findfirst64i32 referenced in function xxx
1>xxx.obj : error LNK2019: unresolved external symbol __imp__wfindnext64i32 referenced in function xxx
1>xxx.obj : error LNK2019: unresolved external symbol __imp__findnext64i32 referenced in function xxx
I can see these unresolved references are declared in stat.h (_stat) and io.h (findfirst/findnext) and should be linked with the CRT but I don't find the correct lib to link with.
Does any body has a clue to solve this problem?
Best regards.
Fred.
There is no spoon.
|
|
|
|
|
Not sure, but it seems a mismatch between the compiler and linker configurations, like compiling for Win64, but linking for Win32.
Can you check the compiler and linker flags ?
2 bugs found.
> recompile ...
65534 bugs found.
|
|
|
|
|
Hello All,
I see some code that looks like this:
string ClassA::operator()(int size1, int size2)
{
....Some function implementation....
}
This appears to me to overload the () operator. Why would someone do this? My understanding of operator overloading is to make code more readable such as with the + and comparison operators.
I would think the implementation for this overloaded operator would be called by:
ClassA c = new ClassA();
string s = c(10, 20);
So, what is the purpose of oerloading the () operator and am I approaching finding where it is called in the code correctly?
Thanks for any help.
Thanks.
|
|
|
|
|
That's a function call operator.
Why? To make the code less readable, of course
Mark Salsbery
Microsoft MVP - Visual C++
|
|
|
|
|
I don't see any need of irony for a perfectly legitimate question,
nor I see any need of such an arrogant answer.
See the next post
[^]
2 bugs found.
> recompile ...
65534 bugs found.
|
|
|
|