|
-
June 14th, 2002, 12:40 AM
#1
Using VB Activex in C++
Hi!
Can anybody tell me how to use Activex Designed in VB in C++ windows aplication in a dialog box.
Can this control come in tool box for designing dialogs in visual studio.
pls let me know if there are some links or some resources on net.
It will be great if you can give a sample code..or tutorial..
Thanks
Naveen
-
June 16th, 2002, 10:18 PM
#2
If you want to place the control in your dialig box You can just use Insert ActiveX Control menu option.
Can you explain your problem in detail?
-
June 16th, 2002, 11:40 PM
#3
Hi!!
Thanks !!!
Can you pls give me an example of code .....with a simple example of how to insert and what code has to be written...
I just made simple activex maybe just a edit box kind and want to use that in windows aplication ..without MFC.
I have put that control on dialog same as what you said .."insert activex control". but now when I run I dont see dialog. Why???
It will be great if you can give me a sample code .... where I can set properties and handle events ...
Can you pls tell me what is a difference between Activex dll and active x control (OCX) in VB
I found one topic in MSDN for ActiveX dll ..It can be used as COM component ...but no document for ActiveX control.
Pls help...
Thanks
Naveen
-
June 17th, 2002, 07:08 AM
#4
Re: Using VB Activex in C++
[ccode]
#define _ATL_APARTMENT_THREADED
#include <atlbase.h>
CComModule _Module;
#include <comdef.h>
#include <atlcom.h>
#impotr "activex_name.ext" rename_namespace("namespace_name")
void main()
{
::CoInitializeEx(NULL, COINIT_APARTMENTTHREADED);
namespace_name::IObjNamePtr pObj;
pObj.CreateInstance(__uuidof(XML: OMDocument));
... // Use oObj
::CoUninitialize();
}
[/ccode]
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|