Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • World
  • Users
  • Groups
Skins
  • Light
  • Cerulean
  • Cosmo
  • Flatly
  • Journal
  • Litera
  • Lumen
  • Lux
  • Materia
  • Minty
  • Morph
  • Pulse
  • Sandstone
  • Simplex
  • Sketchy
  • Spacelab
  • United
  • Yeti
  • Zephyr
  • Dark
  • Cyborg
  • Darkly
  • Quartz
  • Slate
  • Solar
  • Superhero
  • Vapor

  • Default (No Skin)
  • No Skin
Collapse
Code Project
CODE PROJECT For Those Who Code
  • Home
  • Articles
  • FAQ
Community
S

Sid Price

@Sid Price
About
Posts
4
Topics
3
Shares
0
Groups
0
Followers
0
Following
0

Posts

Recent Best Controversial

  • ActiveX components in Regular DLLs
    S Sid Price

    Thanks for the response. I think you are correct about the AfxOleInit call. What I have discovered is that the CWinApp object in my DLL is being created before the CWinApp object in the host application so the Ole init is not done when the dialog in the DLL tries to load the ActiveX component. This has led me to have to rethink the startup of the DLL code because the host application may or may not initialize OLE. I think I need to delay the creation on my DLL based CWinApp object until the host is up and running fully. This is possible, a call already exists for the host to make for that. What may be more difficult is having the DLL know whether OLE is initialized or not so that if the answer is not it can do it. Does this approach sound reasonable? Do you know if there is an API call that would tell the DLL if OLE init had been done? Many thanks for taking the time to respond, Sid

    C / C++ / MFC help com debugging c++ design

  • ActiveX components in Regular DLLs
    S Sid Price

    Hello, I have an application that I need to use some ActiveX components with. First let me describe the structure of the application and then the problem we are having. The application being developed is an add-on or extension for use with third party applications. It is contained in a regular MFC DLL so that it can provide the required "C" type calls for the host application. Because it also has some user interface components it uses a dialog based MFC structure to privide these. We used a regular DLL rather than an extension DLL because the the "host" applications could be written in any language and with any framework, it is an unknown factor outside of our control. However, we did want to use MFC internally. The CWinApp instance in the DLL starts a modal dialog which acts as kind of toolbar for the product. In the OnInitDialog method of this dialog we create several other modeless dialogs for status and data display. Now to the problem. If we place an ActiveX component onto any of the dialogs we get assertions and dialogs fail to create. As a example if the ActiveX components are placed on the main dialog the debug trace view shows the following text: CoCreateInstance of OLE control {50548E24-4550-11D4-A9A7-00400516A5AD} failed. >>> Result code: 0x800401f0 >>> Is the control is properly registered? Warning: CreateDlgControls failed during dialog init. The error is CO_E_FIRST, Moniker enumeration failure. Whatever that means. So, could someone please give us a few pointers here. The InitInstance method of the CWinAp instance in teh DLL has a call to AfxEnableControlContainer. what more is required. The component loads into the test conatiner just fine. It is also visible and appears correctly in the dialog editor. Any help or pointers much appreciated, Thanks Sid

    C / C++ / MFC help com debugging c++ design

  • Toolbar-like Framework?
    S Sid Price

    I would like to design an application that has a caption bar, menu bar, one or more toolbars, and a status bar. There is no document or data to be displayed in any view directly. Does anyone know of a sample application like this? It is similar to the way VB looks in what is called its SDi mode I think. Or any pointers as to how to do this would be helpful. I thought of creating an SDI application and limiting the view frame size but I am not sure if this is the best way, or how to do it! Thanks Sid

    C / C++ / MFC question design tutorial

  • Using updated ActiveX controls
    S Sid Price

    Hi, I have an MFC dialog application that uses an ActiveX component also written by me (in VB). The control has been updated to include some new methods and events. The original control was placed into the dialog resource with the dialog editor and Class Wizard generated the wrapper classes for it. So now the control is updated how do I get the application to use the new control with the new methods available and new events in the dialog class? Thanks Sid

    C / C++ / MFC question c++ com learning
  • Login

  • Don't have an account? Register

  • Login or register to search.
  • First post
    Last post
0
  • Categories
  • Recent
  • Tags
  • Popular
  • World
  • Users
  • Groups