Solved

DCOM Problem on the server (help!)

Posted on 2002-05-23
3
164 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

How your wiki can always stay up-to-date

Quip doubles as a “living” wiki and a project management tool that evolves with your organization. As you finish projects in Quip, the work remains, easily accessible to all team members, new and old.
- Increase transparency
- Onboard new hires faster
- Access from mobile/offline

Join & Write a Comment

Introduction I needed to skip over some file processing within a For...Next loop in some old production code and wished that VB (classic) had a statement that would drop down to the end of the current iteration, bypassing the statements that were c…
I was working on a PowerPoint add-in the other day and a client asked me "can you implement a feature which processes a chart when it's pasted into a slide from another deck?". It got me wondering how to hook into built-in ribbon events in Office.
As developers, we are not limited to the functions provided by the VBA language. In addition, we can call the functions that are part of the Windows operating system. These functions are part of the Windows API (Application Programming Interface). U…
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…

747 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

8 Experts available now in Live!

Get 1:1 Help Now