I've never tried it myself, but this sounds like a job for DCOM. Here's a Microsoft article that walks you through DCOM with VB6. You create an ActiveX exe on machine A, and then VB6 code running on machine B can call into the exe running on machine A. You haven't said what the exe actually needs to do, but presumably you can create one or more methods in a class to do it - whatever it is - and you can pass any necessary information between the machines with the method calls.
Also keep in mind that there are a lot of security risks involved and that you have permissions set to actually connect to the remote system etc ....
thanks. i will try to work on it.
by the way do you have any idea how to access phpmyadmin on a server. i am using xampp and i want to run that on a network and access it using the application i made in visual basic 6?