Interop without interop

  • Thread starter Thread starter Tamir Khason
  • Start date Start date
T

Tamir Khason

Is it possible (if 'yes' - how) to transfer data from VB application to .NET
application and v.v WITHOUT using Interop (very expencive process).
I need to manipulate big bunches of raw data between VB6 and .NET
application (both are running) - done benchmark:
1) XML dom - VERY BAD
2) Interop - BAD
3) Pointers - GOOD and fast, but BAD (unmanaged)

Any ideas how to do it/???
 
Tamir Khason said:
Is it possible (if 'yes' - how) to transfer data from VB application to ..NET
application and v.v WITHOUT using Interop (very expencive process).
I need to manipulate big bunches of raw data between VB6 and .NET
application (both are running) - done benchmark:
1) XML dom - VERY BAD
2) Interop - BAD
3) Pointers - GOOD and fast, but BAD (unmanaged)
Well, unsafe anyway. There are managed pointers
Any ideas how to do it/???

Have you considered using sockets, they are the standard workhorses used in
most situations where large amounts of data need to be transfered(named
pipes can be used as well, but I don't know if VB has support for them and I
know .NET doesn't). Pretty fast, accessible through both VB and .NET, not to
hard to work with.
 
I have a problem with that:
1) VB - builded *not small* applications CAN NOT be rewrited (due client's
budget issues)
2) Working with *really BIG chunks of data and a LOT of iterations (1000
i/sec - 500k each one)

I have a way to do it in optomal low-budget way WITHOUT changing the current
VB application
 
Tamir Khason said:
I have a problem with that:
1) VB - builded *not small* applications CAN NOT be rewrited (due client's
budget issues)
2) Working with *really BIG chunks of data and a LOT of iterations (1000
i/sec - 500k each one)

Hmm, interesting, ok, how does the VB app output its data?
 
Hi Tamir,

In windows, there are many ways of sharing data between processes, such as:
Memory Mapping File(MMF), Named Pipe, CopyData Message, ClipBoard etc..
But normally, all the other technologies use MMF to interprocess
communication(or transfer data).

In the article below, the author tells you the way of using MMF to Cache
and Share data between processes.
And he wrote a class enabled us to read and write data between manage and
unmanaged memory.
http://www.codeproject.com/dotnet/globalcache.asp

Hope this helps,

Best regards,
Jeffrey Tan
Microsoft Online Partner Support
Get Secure! - www.microsoft.com/security
This posting is provided "as is" with no warranties and confers no rights.
 
A well as I already mentioned, Socket is good solution for low iteractional
data, however in this project this not a state...
 
I agree, that unmanaged code is the fastest way to do it, but I want to try
to do it wihout (you know why...))
 
Tamir Khason said:
A well as I already mentioned, Socket is good solution for low iteractional
data, however in this project this not a state...
Well, whatever you do, you have to send it out somehow, its up to you to
send it out. If sockets aren't acceptable, then use memmapped files like
Jeffrey Tan suggested, or any other option.
 
Back
Top