Hi Cory,

The running mbx's can be accessed from the MIPro object by traversing its MBApplications collection, like this :

For Each mbx In mipro.MBApplications
   s = mbx.Name
   If s.ToLower = "relevantapp.mbx" Then 'found it
       Exit For
   End If
Next

Then it's just a question of invoking mbx.Do('xxxx') or mbx.Eval('xxxx')

Remember that .net is case sensitive, most likely also with the mbx file names. Thus the ToLower string comparison.

A caveat I found, is that mbx objects need to be defined as "Object". The MapInfo Interop assembly doesn't seem to handle it very well as a typed variable.


Best regards / Med venlig hilsen
Lars I. Nielsen
GisPro



Cory Martin wrote:
I've never had any problem sending commands to MapInfo from a VB.NET application. I can run all sorts of MapBasic commands and launch MBXs. But I haven't figured out how to reference the individual MapBasic applications I've started to access their RemoteMessageHandlers or invoke their RemoteQueryHandlers. How does one properly set this up in VB.NET?

Best regards,
Cory Martin
_______________________________________________
MapInfo-L mailing list
[email protected]
http://www.directionsmag.com/mailman/listinfo/mapinfo-l

_______________________________________________
MapInfo-L mailing list
[email protected]
http://www.directionsmag.com/mailman/listinfo/mapinfo-l

Reply via email to