473,386 Members | 1,820 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,386 software developers and data experts.

Help onThreading and RaiseEvent ????

Dear all

I have an assembly named Comm.dll which is in charge of handling tcp communication. Inside that assembly I have function which is pooling every 500ms the TCP port for incoming data. That function as been place in a thread that we could named TH1
When data has been detected on TCP port, TH1 raise an event named DataArrive

Then I have a main application window which refer to that comm.dll assembly and whcih has a delegate function responding the DataArrive event raise by TH1. We will call that delegate function GetDataFromTh

When GetDataFromTh1 is called, I process the incoming data and depending of the arrive data I raise en event named DataProcessed inside that delegate function name

Doing this, it gets my all system hanging. Only the mouse is working.

The question is : do we have the right to raise an event in a delegate which is raise in a different thread.

WHat is really happenning and is there any other solution

Reagrds and thanks for your hel

Serge calderar
Maillefer S.

Jul 21 '05 #1
0 908

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

1
by: Guille | last post by:
Hi all! I'm having some weird behaviour in a .NET application i'm developing. I'll try to explain: I've created a Class that wraps an asynchronous socket. When connect callback is called, i...
8
by: Nicolas | last post by:
How do I do a RaiseEvent in csharp I'm ok in VB but csharp confused me a lot. ******* code ******** private FileSystemWatcher watcher = new FileSystemWatcher(); public delegate void...
4
by: Oceania | last post by:
Hi All, I did try using the sample code from the ADO.net forum to link one table, it is working fine. But, I got a problem when I tried to link all tables (20 tables)... Please help, thank...
2
by: Marty | last post by:
Hi, I hope you can help me with this one (my code is below my message). I have many clients connecting to my server. When any of them disconnect, something happen. This user get disconnect...
4
by: AMDRIT | last post by:
I am trying to understand Delegates and where/when to use them. I can see one potential use of a delegate (on form closing, set the cancel property in the event arguments.) Does anyone have a...
0
by: Kooshesh | last post by:
Hello, I have this loop in a function System.Threading.ThreadPool.SetMaxThreads(4, 4) For Each row As DataGridViewRow In DataGridView1.Rows If Not row.Cells(0).Value Is Nothing Then Dim...
0
by: ssabusivefw | last post by:
I am basically writing a server/client application. The client application starts on the login in form where the user is required to enter a user name and password. These are encrypted sent to the...
3
by: Martin | last post by:
Hi all, I'm having a problem when trying to raise an event in my custom control when a toolstripbutton enable state changes. The problem is that although the code to raise the event executes, my...
10
by: hzgt9b | last post by:
Using VS2005, VB.NET, I am developing a windows app. The application opens a couple of forms. While the forms are open I want to raise some events, such as logging errors - but I call RaiseEvent,...
4
by: Ty | last post by:
Hello all, I am creating a website in VS 2008 VB.net. On one of my pages I am using the Table control to make a type of calendar a IN/OUT board. The problem I found after I wrote all the code...
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
0
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
0
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...
0
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.