Solved

DCOM Problem on the server (help!)

Posted on 2002-05-23
3
165 Views
Last Modified: 2010-05-02
I have the following problem:

- project created in VB 6.00, enterprise edition
- client server application using DCOM

Now, this is the problem: Whenever I have a problem on the network, my server hangs, and the application is not responding anymore to any command. I thinks that this is due to the fact that the client is sending some event to the remote server, which is unavailable. This hangs the clients, that is waiting for the ending of the call since the project is single-threaded.

The client is showing a form, so I can't just recompile the project as multi-threaded, since I would have a form for each instance of the client...

Please help me! Any suggestion?
I can increase point to 200.... :))

Thanks in advance...
Marco.
0
Comment
Question by:marconovaro
3 Comments
 
LVL 1

Expert Comment

by:ca_heckler
ID: 7044563
DCOM usually don't behave all that well over a unreliable network connection. I'm not sure you can work around that in VB, as all the ALT/COM fun stuff is hidden.

Have you considering using sockets for the communication? Off course you would have to rely only on simple data types or implement some marshalling on your own, but this way at least you are in the control, and its still all VB.

Thrust-me, it is not that difficult: write a little wrapper object and use it on both sides.
0
 
LVL 6

Author Comment

by:marconovaro
ID: 7046374

Dear ca_heckler,

thanks for the reply. I actually implemented a little workaround to the problem by means of:

- an ActiveX EXE that is multithreaded, and implements the DCOM interface to the clients
- an ActiveX EXE that is single-threaded, and shows the form (I need this because this side is used to communicate on the serial line (!)

This SEEMS to work, because I can also disconnect the net cable, and the server continues working. I actually don't know if this will solve the problem, since I still have to test it on the "unrelaiable network"...
Nevertheless, thanks very much indeed for the answer: I was thinking to change the project to use sockets (avoiding DCOM, that is creating much more mess than help). The problem is that I'm using the same ActiveX EXE both on the server (with COM) an on some clients (with DCOM), so I should be able to use sockets also for the "local" communication.
I'll check how difficult it is for me to change the project itself.

Thanks again.
0
 
LVL 6

Accepted Solution

by:
Mindphaser earned 0 total points
ID: 7127337
Points refunded and moved to PAQ

** Mindphaser - Community Support Moderator **
0

Featured Post

Is Your Active Directory as Secure as You Think?

More than 75% of all records are compromised because of the loss or theft of a privileged credential. Experts have been exploring Active Directory infrastructure to identify key threats and establish best practices for keeping data safe. Attend this month’s webinar to learn more.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Most everyone who has done any programming in VB6 knows that you can do something in code like Debug.Print MyVar and that when the program runs from the IDE, the value of MyVar will be displayed in the Immediate Window. Less well known is Debug.Asse…
If you need to start windows update installation remotely or as a scheduled task you will find this very helpful.
Get people started with the process of using Access VBA to control Excel using automation, Microsoft Access can control other applications. An example is the ability to programmatically talk to Excel. Using automation, an Access application can laun…
Show developers how to use a criteria form to limit the data that appears on an Access report. It is a common requirement that users can specify the criteria for a report at runtime. The easiest way to accomplish this is using a criteria form that a…

910 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

21 Experts available now in Live!

Get 1:1 Help Now