Quick Search for:  in language:    
DDE,HTML,Learn,method,dynamically,exchanging,
   Code/Articles » |  Newest/Best » |  Community » |  Jobs » |  Other » |  Goto » | 
CategoriesSearch Newest CodeCoding ContestCode of the DayAsk A ProJobsUpload
Visual Basic Stats

 Code: 3,011,557. lines
 Jobs: 115. postings

 How to support the site

 
Sponsored by:

 

You are in:

 
Login



Latest Code Ticker for Visual Basic
Locate Database
By Erica Ziegler-Roberts on 6/30


Organize the errors of your programs
By Toni on 6/30


how to open and close access database
By Freebug on 6/29


Click here to see a screenshot of this code!PSC-Browser
By Ralph LONG Metz on 6/29

(Screen Shot)

Click here to see a screenshot of this code!Quadratic Solver 2
By Guillaume Couture-Levesqu e on 6/29

(Screen Shot)

Click here to see a screenshot of this code!Array Example
By Cold Fire on 6/29

(Screen Shot)

Click here to see a screenshot of this code!Reconstructor 3.0
By Peter Scale on 6/29

(Screen Shot)

Click here to see a screenshot of this code!Subtitles Manager
By KarahaNa on 6/29

(Screen Shot)

XPlorer
By ZProse on 6/29


Click here to put this ticker on your site!


Add this ticker to your desktop!


Daily Code Email
To join the 'Code of the Day' Mailing List click here!





Affiliate Sites



 
 
   

Easy COM based Multichannel Dynamic Data Exchange (DDE) Between Apps - With InterCommVB II (Updated)

Print
Email
 

Submitted on: 8/1/2001 11:48:47 PM
By: Srideep Prasad  
Level: Advanced
User Rating: By 109 Users
Compatibility:VB 5.0, VB 6.0

Users have accessed this article 16000 times.
 
(About the author)
 
     Learn a new method of dynamically exchanging data between apps - with InterCommVB II. With unparalled power and ease of use, InterCommVB truly allows you to get the max output from minimum code. So you no longer need to tamper around with DDE APIs and other hard Win32 APIs. InterCommVB truely makes implementing DDE a breeze - even a beginner could be implementing DDE with this component. The package also includes an HTML file to help you understand the concepts better, in case you are a newbie ! This version is updated to include a host of new features !

This article has accompanying files

 
 
Terms of Agreement:   
By using this article, you agree to the following terms...   
1) You may use this article in your own programs (and may compile it into a program and distribute it in compiled format for languages that allow it) freely and with no charge.   
2) You MAY NOT redistribute this article (for example to a web site) without written permission from the original author. Failure to do so is a violation of copyright laws.   
3) You may link to this article from another website, but ONLY if it is not wrapped in a frame. 
4) You will abide by any additional copyright restrictions which the author may have placed in the article or article's description.
What is Interprocess Communnication

What is Interprocess Communnication(IPC)

IPC is a technology that enables two or more running apps to exchange data dynamically with each other

InterProcess Communication - The Problems
Microsoft Windows comes with a variety of ways to implement Inter Process Communication (IPC). Notable among these are the Dynamic Data Exchange (DDE) APIs, Mailslots and Pipes. 


DDE allows applications to communicate with each other dynamically. But implementing DDE is no easy job - the DDE APIs tend to be highly complicated and difficult to implement, especially for the VB programmer.  
MailSlots and Pipes are basically technologies wherein virtual temp files are created in the RAM and can be used by apps to store shareable data. This technique does not tend to be straightforward either and these methods by itself do not provide notification mechanisms !
Of course, you could use temp files, but this method is cumbersome and slow... Then how do we implement Inter Process Communication (IPC) ? Simple - We harness the potential of Microsoft's powerful COM based ActiveX Technology !

Easy and Efficient Interprocess Communication (IPC) with InterCommVB 1.00
InterCommVB allows developers to implement IPC very easily. With just a few easy to understand calls to this component from the client and server sides, one can efficiently implement easy and effective interprocess communication
What's more - InterCommVB allows multiple data communication channels to be open and for one channel say if App A is the Server App and if App B is the Client then for another channel App A could act as the Client and App B could act as the server ! That's truly two way communication ! And of course, this ActiveX EXE comes with an inbuilt notification system that notifies both the server and client sides of the data transmission status ! What's more - this component is multithreaded, that is if one communication channel is blocked or busy, other channels remain unaffected. And the component now implements real time asynchronous communication, so no more worries about the server app getting "stuck" waiting for the client app to process transmitted data. This component now also defines an updated internal error handling interface...
 IF YOU FIND IT USEFUL, PLEASE VOTE. THANK YOU !

          


winzip iconDownload article

Note: Due to the size or complexity of this submission, the author has submitted it as a .zip file to shorten your download time. Afterdownloading it, you will need a program like Winzipto decompress it.

Virus note:All files are scanned once-a-day by Planet Source Code for viruses,but new viruses come out every day, so no prevention program can catch 100% of them.

FOR YOUR OWN SAFETY, PLEASE:
1)Re-scan downloaded files using your personal virus checker before using it.
2)NEVER, EVER run compiled files (.exe's, .ocx's, .dll's etc.)--only run source code.
3)Scan the source code with Minnow's Project Scanner

If you don't have a virus scanner, you can get one at many places on the net including:McAfee.com

 
Terms of Agreement:   
By using this article, you agree to the following terms...   
1) You may use this article in your own programs (and may compile it into a program and distribute it in compiled format for languages that allow it) freely and with no charge.   
2) You MAY NOT redistribute this article (for example to a web site) without written permission from the original author. Failure to do so is a violation of copyright laws.   
3) You may link to this article from another website, but ONLY if it is not wrapped in a frame. 
4) You will abide by any additional copyright restrictions which the author may have placed in the article or article's description.


Other 8 submission(s) by this author

 

 
Report Bad Submission
Use this form to notify us if this entry should be deleted (i.e contains no code, is a virus, etc.).
Reason:
 
Your Vote!

What do you think of this article(in the Advanced category)?
(The article with your highest vote will win this month's coding contest!)
Excellent  Good  Average  Below Average  Poor See Voting Log
 
Other User Comments
8/3/2001 5:39:34 AM:Srideep Prasad
Though many authors may sell of their code as shareware I believe in giving them free. Therefore, if this code is of use to you,please vote ... Thank you !
Keep the Planet clean! If this comment was disrespectful, please report it:
Reason:

 
8/3/2001 1:55:38 PM:netkarma
Your article and code seem to be convincing...one question though, can it be used to communicate with any existing app on the system? eg: My VB app needs to communicate with Netscape Navigator and issue certain commands at run time... Your response is greatly appreciated. Good code, nonetheless,
Keep the Planet clean! If this comment was disrespectful, please report it:
Reason:

 
8/3/2001 10:58:49 PM:Srideep Prasad
netkarma - I will reply to your querry personally by e-mail
Keep the Planet clean! If this comment was disrespectful, please report it:
Reason:

 
8/4/2001 3:55:05 AM:Jon
I have a situation where I already use an ActiveX EXE to communicate between different threads. One of the problems I encountered was not being able to transport UDT's between client and server as they are not allowed in public methods. Would you see this as a problem for your implementation?
Keep the Planet clean! If this comment was disrespectful, please report it:
Reason:

 
8/5/2001 9:50:42 PM:Srideep Prasad
Jon, I have personally replied to your querry by e-mail
Keep the Planet clean! If this comment was disrespectful, please report it:
Reason:

 
8/7/2001 2:36:16 AM:Matrix
Like netkarma, I'd like to know if that is possible to communicate with existing programs. can you also reply to me personnaly?
Keep the Planet clean! If this comment was disrespectful, please report it:
Reason:

 
8/7/2001 11:55:58 AM:Srideep Prasad
Matrix - I have send a personal reply to your question by e-mail.Hope you find it useful !
Keep the Planet clean! If this comment was disrespectful, please report it:
Reason:

 
8/8/2001 9:39:54 AM:Verburgh Peter
Nice , it als getting better and better! i've thaught i've already voted , but wrong.. so you get now 5 globel ! Keep up with the updates ! Peter Verburgh
Keep the Planet clean! If this comment was disrespectful, please report it:
Reason:

 
8/8/2001 9:44:36 PM:Srideep Prasad
As the author, I thank all of you personally for your tremendous reponse to my effort ! Thank You !
Keep the Planet clean! If this comment was disrespectful, please report it:
Reason:

 
8/9/2001 2:10:49 PM:Act
Please let me know how can I communicate with existing application i.e. send command/data to existing application?
Keep the Planet clean! If this comment was disrespectful, please report it:
Reason:

 
8/9/2001 2:22:38 PM:ahp
Like other users, I'd like to know if that is possible to communicate with existing programs?. Normally using DDE I will have to specify a
Keep the Planet clean! If this comment was disrespectful, please report it:
Reason:

 
8/9/2001 10:15:29 PM:Srideep Prasad
Ahp, Act - Check your e-mail. I have replied to you personally by e-mail
Keep the Planet clean! If this comment was disrespectful, please report it:
Reason:

 
8/9/2001 10:15:36 PM:Srideep Prasad
Ahp, Act - Please check your e-mail. I have replied to you personally by e-mail
Keep the Planet clean! If this comment was disrespectful, please report it:
Reason:

 
8/12/2001 4:30:12 AM:frank
why not just post your
Keep the Planet clean! If this comment was disrespectful, please report it:
Reason:

 
8/12/2001 6:35:13 AM:________
Great code. 5 blobs from me.
Keep the Planet clean! If this comment was disrespectful, please report it:
Reason:

 
8/12/2001 9:31:35 PM:Tigger
Neat - interesting code (gave you 5 blobs). Question for you tho': I am only able to open 1 client & 1 server (at least thru the demo's). Is this a limitation or can you have multiple clients per server? T
Keep the Planet clean! If this comment was disrespectful, please report it:
Reason:

 
8/12/2001 10:24:03 PM:Srideep Prasad(author)
Tigger - There is a way round your problem which I have mailed you by e-mail.Hope you find it useful
Keep the Planet clean! If this comment was disrespectful, please report it:
Reason:

 
8/13/2001 2:33:07 AM:Gremio
I was wondering if you knew a way I could get information from current programs ones that I did not create thank you ---
Keep the Planet clean! If this comment was disrespectful, please report it:
Reason:

 
8/13/2001 3:43:40 AM:ARAM
VERY GOOD CODE! I've read your previous submission about miltithreading in VB using ActiveX EXE - that was a VERY STABLE solution, too! I rated your submission 5 globes, I feel it's not enough... I've also seen Robert Thaggard's submission about multithreading in VB using a callback DLL. His submission is, I'm not afraid of saying this, a fraud! And he even dares to say that his solution is better than yours...he's got no solution at all.
Keep the Planet clean! If this comment was disrespectful, please report it:
Reason:

 
8/13/2001 11:50:04 AM:Vrej
I have a situation where I already use an ActiveX EXE to communicate between different threads. One of the problems I encountered was not being able to transport UDT's between client and server as they are not allowed in public methods. CAN YOU PLEASE FORWARD ME THE EMAIL YOU SENT TO JON? ALSO, I HAVE TRIED A WORKAROUND BY USING A CLASS WITH PUBLIC VARIABLES INSTEAD OF A UDT, BUT IT BECOMES A PROBLEM WHEN I HAVE TO RETURN AN ARRAY OF CLASSES, AND IM RETURNING IT TO ASP!!
Keep the Planet clean! If this comment was disrespectful, please report it:
Reason:

 
8/13/2001 9:45:06 PM:Roy
just want to know if this can be done with the client and server are in different PCs on a network?, I already voted it to the max. Just want to ask it again.
Keep the Planet clean! If this comment was disrespectful, please report it:
Reason:

 
8/13/2001 11:44:49 PM:Srideep Prasad
VRej, I have a solution based on the CopyMemory API. Check out your e-mail. I have mailed you the solution
Keep the Planet clean! If this comment was disrespectful, please report it:
Reason:

 
8/14/2001 10:11:59 AM:Juan Martin Diaz
I want to know how to do it on a network too please! And with other installed apps.
Keep the Planet clean! If this comment was disrespectful, please report it:
Reason:

 
8/15/2001 9:42:03 AM:Mussel
I gave you 5 blobs also - ease of use is a great plus. Have you ever tried to make 2 way peer-to-peer communicaiton out of it? I'd be interested.
Keep the Planet clean! If this comment was disrespectful, please report it:
Reason:

 
8/15/2001 10:30:58 AM:Ultimatum
There is a way to perform inter-process communication over a network (and even over the Internet if you know how), but I'm afraid it requires the use of mailslots.
Keep the Planet clean! If this comment was disrespectful, please report it:
Reason:

 
8/15/2001 1:25:07 PM:Srideep Prasad
I will reply to all your querries by e-mail soon. I think the suggestion of Ultimatum, about using mailslots is feasible, but as he said, it may be a bit inconvinient
Keep the Planet clean! If this comment was disrespectful, please report it:
Reason:

 
9/20/2001 11:09:54 AM:Joe Fuentes
I would love to get the answers to most of the questions asked could you send them all to me too it looks great.
Keep the Planet clean! If this comment was disrespectful, please report it:
Reason:

 
9/22/2001 3:12:27 AM:ElctriX
I'd like to know if that is possible to communicate with existing programs. can you also reply to me personnaly? I give you 5 globes.
Keep the Planet clean! If this comment was disrespectful, please report it:
Reason:

 
9/25/2001 4:52:48 AM:Mohan
Nice code, 5 Globes.... can u give any practical example where we can implement this concept.
Keep the Planet clean! If this comment was disrespectful, please report it:
Reason:

 
9/27/2001 5:00:35 AM:AnDy2552
can it be used to communicate with any existing app on the system?
Keep the Planet clean! If this comment was disrespectful, please report it:
Reason:

 
9/27/2001 5:02:09 AM:AnDy2552
can it also communicate with another app residing on another peer computer application??
Keep the Planet clean! If this comment was disrespectful, please report it:
Reason:

 
9/27/2001 12:39:21 PM:ROtt
How 'bout making your replies about other Apps and networking public? Thanks for sharing the code!!!
Keep the Planet clean! If this comment was disrespectful, please report it:
Reason:

 
9/27/2001 4:35:54 PM:raf
Hey, good job so far..... but what if you want to transmit other data then strings (for instance COM Objects)? Another thing, what if you want one server to transmit to multiple clients? I was not able to start multiple clients at the same time.
Keep the Planet clean! If this comment was disrespectful, please report it:
Reason:

 
9/28/2001 11:42:42 AM:Srideep Prasad
Please note that InterCommVB uses a entirely new method of performing DDE and it is not compatible with
Keep the Planet clean! If this comment was disrespectful, please report it:
Reason:

 
9/28/2001 4:41:03 PM:Mr_puniverse00
I know that this has been asked before, but could you please e-mail about how to communicate with existing apps too?
Keep the Planet clean! If this comment was disrespectful, please report it:
Reason:

 
9/29/2001 6:19:39 AM:AlkanMM
I too would like to compliment you on providing the code (5 globes). How about transferring COM objects amongst multiple clients? I'm anticipating a FAQ sometime soon.
Keep the Planet clean! If this comment was disrespectful, please report it:
Reason:

 
9/29/2001 6:21:19 AM:AlkanMM
5 Globes for sharing great code! How to send COM objects to multiple clients? I'm anticipating a FAQ soon......
Keep the Planet clean! If this comment was disrespectful, please report it:
Reason:

 
10/1/2001 4:15:08 AM:Victor
The most elaborate shared code in this domain I have seen so far. But please, instead of replying personally to questions or suggestions posted here, why not just post here the new improved versions ? This behaviour I don't understand at all... 5 rounds from me.
Keep the Planet clean! If this comment was disrespectful, please report it:
Reason:

 
10/1/2001 7:02:13 AM:Sridee Prasad
As I have said before (few comments earlier), InterCommVB II's DDE techniqes are entirely novel and cannot be used with existing apps that implement
Keep the Planet clean! If this comment was disrespectful, please report it:
Reason:

 
10/1/2001 7:04:20 AM:Srideep Prasad
InterCommVB's DDE techniques cannot be used for communication with existing apps that implement "standard" DDE techniques.Also it has not been designed to be implemented on a network.
Keep the Planet clean! If this comment was disrespectful, please report it:
Reason:

 
10/23/2001 5:13:25 AM:Zee
This is great!!! 5 Globes from me..
Keep the Planet clean! If this comment was disrespectful, please report it:
Reason:

 
11/28/2001 6:49:21 PM:Peter Verburgh
This is great , now i have the time to study and look at your project. i hope you know me .. Net Watch V2.1 ? My question is can i mail you personally , if i have some little questions about this great communication between 2 apps ? If so , then i will tell you what i want to program , my email: peter.verburgh2@yucom.be Greetings, Peter.
Keep the Planet clean! If this comment was disrespectful, please report it:
Reason:

 
1/8/2002 12:17:25 PM:Mirco
Hi, I'am an italian students, and i'm trying to use InterCommVB in my Thesys Project, for allow DDE comunication between VB application. I think IntercommVB is fantastic, but i had some problem when i whant to close the channel from the server. In the API i see that in IServer.disconnectfromchannel there isn't the parameter channelID so i'm not able to disconnet the server from the channel, to allow other application to connect in the same channel There is an error in the library? I'm in error in using it? Have you had similar problem? Thank'you PS: sorry for my orrendus english :)
Keep the Planet clean! If this comment was disrespectful, please report it:
Reason:

 
1/8/2002 9:39:15 PM:Srideep Prasad
Micro, There's no error in the library. This ChannelID parameter is not required to disconnect from a channel since InterCommVB internally keeps track of the channel id. I will clear your doubts with a better explanation which I shall send via e-mail
Keep the Planet clean! If this comment was disrespectful, please report it:
Reason:

 
2/19/2002 1:01:56 AM:Joel Konecny
good job on the project... i gave you 5 globes although that was not completely my decision ;)... i am gonna have to remember that little trick you pulled. i would have givin you 5 globes anyway, even without you trickin me into it lol... good job.
Keep the Planet clean! If this comment was disrespectful, please report it:
Reason:

 
4/24/2002 8:29:39 AM:pHroZeN GeeK
Thanks for the cool code man!!! 5 globes from me... Please let me know that if this technology can be used to communicate with other existing programs like IE etc... Your reply will be greatly appreciated... One more things I wanted to ask, whats the advantage of using this VBInterComm over the easy WinSock control??? please let me know that... Very nice code... Regards, Ali Akbar (pHroZeN GeeK)
Keep the Planet clean! If this comment was disrespectful, please report it:
Reason:

 
5/8/2002 8:32:49 AM:Jack
This code is awesome. Please let me know that if this technology can be used to communicate with other existing programs Thanks,
Keep the Planet clean! If this comment was disrespectful, please report it:
Reason:

 
6/9/2002 12:08:47 PM:amir reza niakan
I have worked by vb for 1 year
Keep the Planet clean! If this comment was disrespectful, please report it:
Reason:

 
6/24/2002 12:18:25 PM:Qtronix
Quite amazed by your excellence in coding, fully documented with understandable code. Ah, so much to learn from you! :) 5 outta 5!
Keep the Planet clean! If this comment was disrespectful, please report it:
Reason:

 
8/26/2002 6:07:23 PM:Zebo
Sorry man, but i don't think this is that good. Sure it can communicate between other apps, but only apps that you have the source code for or have this source code installed. That's easy, you can just make a file that all the other files read out of. When you think about it that's actually much easier then getting into what you have gotten into. Now, it's still very nice. But there are easier ways. Now, if the program could retrieve and perform events from a program that you haven't made or has this source code installed in it very easily... That would be amazing.
Keep the Planet clean! If this comment was disrespectful, please report it:
Reason:

 
4/11/2003 8:15:17 AM:Thomas Sturm
Hello Srideep! this is one of the very rare examples of excellence on PSC. Just for ideas like that, properly coded, it´s worth having this site - even if most comments suggest that not many people know what it´s all about ;-) Thank you very much for this contribution - and another 5...
Keep the Planet clean! If this comment was disrespectful, please report it:
Reason:

 
5/8/2003 12:35:28 PM:
I'm interested in knowing if this would work with other windows Apps?
Keep the Planet clean! If this comment was disrespectful, please report it:
Reason:

 
5/8/2003 12:36:08 PM:
Please I'm also interested in knowing if this works with other windows Apps
Keep the Planet clean! If this comment was disrespectful, please report it:
Reason:

 
Add Your Feedback!
Note:Not only will your feedback be posted, but an email will be sent to the code's author in your name.

NOTICE: The author of this article has been kind enough to share it with you.  If you have a criticism, please state it politely or it will be deleted.

For feedback not related to this particular article, please click here.
 
Name:
Comment:

 

Categories | Articles and Tutorials | Advanced Search | Recommended Reading | Upload | Newest Code | Code of the Month | Code of the Day | All Time Hall of Fame | Coding Contest | Search for a job | Post a Job | Ask a Pro Discussion Forum | Live Chat | Feedback | Customize | Visual Basic Home | Site Home | Other Sites | About the Site | Feedback | Link to the Site | Awards | Advertising | Privacy

Copyright© 1997 by Exhedra Solutions, Inc. All Rights Reserved.  By using this site you agree to its Terms and Conditions.  Planet Source Code (tm) and the phrase "Dream It. Code It" (tm) are trademarks of Exhedra Solutions, Inc.