473,387 Members | 1,455 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,387 software developers and data experts.

How to use running ActiveX exe in another program instance ?

Hello,

I have Mapoint software installed on my machine.
Now, in VC++, I can use this mapoint application in my program as
below-
_Application mapapp;
_Map map;

if( mapapp.CreateDispatch ("MapPoint.Application")){
mapapp.SetVisible (FALSE);
map=mapapp.GetActiveMap ();
map.SetMapStyle (0) ;
mappointInstalled=true;
}else{
mappointInstalled=false;
}

But, the problem is that when I run multiple instances of my program,
it starts those many instances of mapoint. That is very resource
consuming.

Is it possible to check if an instance of mappoint is already running
& if so, use this running mappoint in next instance of my program?
Please suggest some solution.

Thanks in advance.
Jul 23 '05 #1
1 2482
On 13 Mar 2005 21:14:13 -0800, pr*****************@yahoo.com (Mandhare
Prashant) wrote in comp.lang.c++:
Hello,

I have Mapoint software installed on my machine.
Now, in VC++, I can use this mapoint application in my program as
below-
_Application mapapp;
_Map map;

if( mapapp.CreateDispatch ("MapPoint.Application")){
mapapp.SetVisible (FALSE);
map=mapapp.GetActiveMap ();
map.SetMapStyle (0) ;
mappointInstalled=true;
}else{
mappointInstalled=false;
}

But, the problem is that when I run multiple instances of my program,
it starts those many instances of mapoint. That is very resource
consuming.

Is it possible to check if an instance of mappoint is already running
& if so, use this running mappoint in next instance of my program?
Please suggest some solution.

Thanks in advance.


C++ does not have ActiveX, or multiple instances either. These are
Microsoft specific extensions for Windows. Ask in
news:comp.os.ms-windows.programmer.win32 where the experts on such
things are.

--
Jack Klein
Home: http://JK-Technology.Com
FAQs for
comp.lang.c http://www.eskimo.com/~scs/C-faq/top.html
comp.lang.c++ http://www.parashift.com/c++-faq-lite/
alt.comp.lang.learn.c-c++
http://www.contrib.andrew.cmu.edu/~a...FAQ-acllc.html
Jul 23 '05 #2

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

8
by: AnalogKid | last post by:
Short question: What's the difference between SingleUse and MultiUse ? Long question: I've been writing some sample code to see how different Instancing values and threading models work. I...
6
by: Pierre-Yves | last post by:
Hello, I would like to prevent my perl program to be executed several times simultaneously (if the program is already running, I would like to display a message like "another instance of this...
2
by: Fie Fie Niles | last post by:
This one XP machine (with IE 6) is having a problem viewing any ActiveX controls (created on VB6) on the Internet Explorer browser. I put the same ActiveX control in a VB program, and when I run...
0
by: Craig | last post by:
I am having problems getting an ActiveX DLL written in VB6 to call a method in a C# class library component. My C# DLL is called CSharpProject.dll and contains a public class called CSharpClass....
2
by: VB Programmer | last post by:
I have a VB.NET winform app that I created that uses an ActiveX control (cwui.ocx). I created a setup project for it and it installs fine on my machine. The app runs fine too. When I run it...
1
by: Patrick Dugan | last post by:
Is it possible to get the handle of a running service? I have a program (ActiveX program) running in memory. When I start my service I need to pass the service's handle to that program in order...
3
by: Geoff Coope | last post by:
Hi all I created an ASP ActiveX DLL file in Delphi that works great using ASP on IIS. Is it possible to use ActiveX DLL files within PHP like in ASP? but on an Apache webserver that is...
20
by: Bradley | last post by:
Hey all, Another convert to vb.net here. My vb6 program was an application launcher that checked for previous instances of said programs and would alert the user with a message box. I can't, for...
1
by: Tobias Maier | last post by:
Hi I want to start a C# ActiveX Exe with a parameter. Now, start a WebBrowser. Within Html/javascript I initiate my component und want to retrieve the parameter from the startet exe. I have...
0
by: taylorcarr | last post by:
A Canon printer is a smart device known for being advanced, efficient, and reliable. It is designed for home, office, and hybrid workspace use and can also be used for a variety of purposes. However,...
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
0
by: aa123db | last post by:
Variable and constants Use var or let for variables and const fror constants. Var foo ='bar'; Let foo ='bar';const baz ='bar'; Functions function $name$ ($parameters$) { } ...
0
by: ryjfgjl | last post by:
If we have dozens or hundreds of excel to import into the database, if we use the excel import function provided by database editors such as navicat, it will be extremely tedious and time-consuming...
0
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
0
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...
0
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.