Hello,
I'm having some trouble getting a web-page indexing program to work. I have a form that automatically downloads URLs to index from a database server and sends back responses containing the indexed page information, over UDP. I have a static class called UDP that keeps track of incoming and outgoing messages. There is an event that fires whenever a message is recieved, which the form that contains all the indexing code hooks to keep track of messages sent from a program on the server that holds the database of urls to index.
This was all working fine, until I added another form that appears before the indexing form. Now, the indexing form opens on another thread (through Application.Run() and a second thread). The problem is, the event handler is no longer called when the event is fired.
So, the question is, what is going on here, and what can I do to fix it? I'm pretty sure it has to do with some cross-thread safety mechanism that doesn't call event handlers on another thread than the one the event was fired from. Does anybody know of a different way to do this or a way to circumvent this? Thanks in advance...