COM Question

Tech-Archive recommends: Repair Windows Errors & Optimize Windows Performance



Hi,

We currently have a large library of COM objects written
in C++ that talk to different devices. Then we have several
applications that can host these objects. The simplest of
which just wraps the objects and displays their custom
GUIs. If you register a new dll, then it shows up in the
list as an available device in the various host applications.

I'm trying to duplicate this behavior for a mobile version of
our software. I'm afraid you may not be able to do what
I want in Compact Framework. The new app is C#.
What I'd like to do is get a list from the registry of installed
objects, and load them dynamically. To give a layman's
example, I'd have several implementations of IVCR in
various DLLs, and I could list the name brands listed in
the app for the ones installed, when they click on, say
Sony - X1234, then it would load the proper COM
object, which would display it's GUI. This way I can
just install a new DLL when we add a new device
to the software. Then I can just call IVCR.Record()
on each of them, and they'd each work. The apps would
have no prior knowledge of Sony, but would IVCR.

We've done this many times in the world of PC C++, but
not sure if we can do it for our PocketPC apps.

I have implemented a UserControl Library dll and a dll
that defines the interface, and had the UserControl implement
the interface, but so far I'm just placing the control on
the gui in form designer of Visual Studio. Ideally I'd like
to do something like:

//psuedo code
OnDeviceSelectionChange(){
IVCR obj;
//App doesn't know about "SonyX1234"
//instead gets list of installed "devices" from registry
//so user can choose at runtime
obj.CoCreateInstance("SonyX1234");
obj.Show(x,y,cx,cy);
obj.Record();
}

(the vcr is just an example, not a true representation
of the industry specific devices we're dealing with)

Is this possible?

Thanks in advance,

Steven


.



Relevant Pages

  • Re: Smalltalk w/o IDE, etc.?
    ... Would I have to run the IDE on the remote host? ... We run VisualWorks programs as headless applications. ... Smalltalk app in headless mode; otherwise, it would be rather useless for many types of app hosting. ...
    (comp.lang.smalltalk)
  • Re: Best way to auto-start Remoting host that is a Windows Forms app?
    ... Currently I am just trying using Process.Start to launch the host app from ... wrapping it up into a client-side DLL for reuse and encapsulation. ... The requirement now is that the client "touches" the dll before going ...
    (microsoft.public.dotnet.framework.remoting)
  • Re: Should Globally Needed Objects be Members in Main Frame, Application, or be Global?
    ... applications. ... so I mostly only use this mechanism where I would normally use AfxGetApp() ... application from a DLL, but I wouldn't call AfxGetAppfrom a DLL either. ... If we followed this(touching an object which is included in App), ...
    (microsoft.public.vc.mfc)
  • Re: Deploying compiled Class File (dll) for website
    ... any helper "background" applications that may run on the webserver also ... needing the DLL. ... and simply copy your DLL to the bin folder under your deployed ... > by making copies of it and placing them in the bin folders of each app. ...
    (microsoft.public.dotnet.framework.aspnet)
  • Re: whats the status with atlas?
    ... But it's possible to tag a dll to increase the security stuff, ... the reason i ask is that i was i've set up an ajax.net app and run it fine ... So, no, the host shouldn't have to register ...
    (microsoft.public.dotnet.framework.aspnet)