Solved

OCX controls without MFC

Posted on 1998-09-07
4
401 Views
Last Modified: 2013-12-04
I am trying to write a windows program without using MFC but I am having trouble understanding how to use the OCX controls, specifically the ms access calendar control. I am using VC++ 4.0 on win 950b.  I have used this control many times with MFC, clazzwizard automatically created the implementation files.  I don't want to use MFC because I am trying to create a small executable.(as a matter of fact I did use MFC at first and was dissatified with the size of the files needed for installation)
0
Comment
Question by:TheDragon
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 2
  • 2
4 Comments
 
LVL 23

Accepted Solution

by:
chensu earned 150 total points
ID: 1414262
That's not trivial. You have to write an ActiveX Control Container in order to use it. Look into the Platform SDK (or formerly ActiveX SDK) documentation about ActiveX Control Containers. I don't think it is worth doing so if you just want a smaller code. The size won't be reduced significantly.


"ActiveX Control Containers

The purpose of this topic is to provide guidelines for implementing containers that will interoperate well with other controls and containers. This document defines the minimum set of interfaces, methods, and features that are required of ActiveX™ containers to accomplish seamless and useful interoperability.

Overview
ActiveX Control Containers
General Guidelines
Related Topics"
0
 

Author Comment

by:TheDragon
ID: 1414263
I realize its not a trivial task, thats why I am asking 4 help.  And not just for this program but for pragramming windows in general.  I don't want to use MFC.  I don't like it and would prefer to just write windows programs in C++.  Unfortunately MS doesn't document well how to do certain task outside of MFC.

IF you can give me a fairly detailed outline of the steps I need to take to use a ocx control in a c++ program and any gotchas to watch out for I will give you the points.  Or even if you can point me at a single program somewhere out on the web that does it.  Closest I have found are programs that use OLE to connect/control  other running programs, but nothing that embeds a control in a program.
0
 
LVL 23

Expert Comment

by:chensu
ID: 1414264
Besides the documentation I mentioned, here is an article

The Makings Of An OCX Container
http://users.neca.com/vmis/final1.htm

Although it uses MFC framework to build the program, it does implement the interfaces without using the readymade MFC ActiveX Control container.

Hope it helps.
0
 

Author Comment

by:TheDragon
ID: 1414265
I believe this is just what I was looking for, havn't had a chance to read completely through it but so far it seems to be heading in the same direction I am.

Thanks
Dragon
0

Featured Post

Free Tool: Path Explorer

An intuitive utility to help find the CSS path to UI elements on a webpage. These paths are used frequently in a variety of front-end development and QA automation tasks.

One of a set of tools we're offering as a way of saying thank you for being a part of the community.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

With most software applications trying to cater to multiple user needs nowadays, the focus is to make them as configurable as possible. For e.g., when creating Silverlight applications which will connect to WCF services, the service end point usuall…
For most people, the WrapPanel seems like a magic when they switch from WinForms to WPF. Most of us will think that the code that is used to write a control like that would be difficult. However, most of the work is done by the WPF engine, and the W…
This is Part 3 in a 3-part series on Experts Exchange to discuss error handling in VBA code written for Excel. Part 1 of this series discussed basic error handling code using VBA. http://www.experts-exchange.com/videos/1478/Excel-Error-Handlin…

738 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question