|
|
Comments and Discussions
|
|
 |

|
Sign with a REAL certificate info
|
|
|
|

|
Dear All
There was a question needs everyone help.
As the post I done.
I can display as this.
I had added one "Edit Box" to my project,but I cant type anythings in my editbox.
does anyone tell me?
|
|
|
|

|
I've created an invisible control with just a method that Javascript can call. Its works fine in my machine but not if i unregister and make a cab file, sign it and host in webserver. I get the red X box. Any idea what I'm missing?
here the details
1. In the control creation step, default it to none (instead of "static").
2. invisible control.
3.it has a dispatch method int he contol cpp a sayHello.
BSTR CMyActivexCtrl::sayHello(void)
{
AFX_MANAGE_STATE(AfxGetStaticModuleState());
CString strResult;
strResult = "hello: world!!" ;
// TODO: Add your dispatch handler code here
return strResult.AllocSysString();
}
4. Made it safe for scripting and Initialization.
5. build the control in my machine which registers the control in the registry.
6. If i just run in a browser with the classid, its working.
7. Now, if I unregister and build a cab file and sign it and place in the web server access it. it shows a red X box. is there anything missing?
here the INI fie.
[version]
signature="$CHICAGO$"
AdvancedINF=2.0
[Add.Code]
MyActivex.ocx=MyActivex.ocx
MyActivex.ini=MyActivex.ini
[MyActivex.ocx]
file-win32-x86=thiscab
clsid={2B281EA9-5871-4900-8BE0-8A46DFCECE95}
FileVersion=1,0,0,1
RegisterServer=yes
[MyActivex.ini]
file=thiscab
Any help is much appreciated.
Regards
Gopal
|
|
|
|

|
I've a COleControl and add lots of events for javascript.
when I call the event method at a object mehod as following:
void CMyOcxCtrl::BtnMethod()
{
this->OnStartAction();//OnStartAction is built as this article;
}
And this event is correctly fired by javascript.
But I want to use a static dispatcher for other objects call, as the following(use a static reference):
static void CMyOcxCtrl::EventDispatcher(EVENT_DISP ed)
{
switch(ed)
{
edStartAction: CMyOcxCtrl::pInstance->OnStartAction();
::MessageBox(NULL, "Fire StartAction Event", "", MB_OK);
}
}
Event is not fired, but MessageBox showed.
Then I try to use the reference statement in the obj method I metioned, it works.
void CMyOcxCtrl::BtnMethod()
{
CMyOcxCtrl::pInstance->OnStartAction();
}
Could you tell me how to solve this problem, thanks.
|
|
|
|

|
My ActiveX control works fine in Excel, but graphical objects (lines, curves, etc.) are always hidden by that control, although their z-order is topmost...
I know that there must be a solution, since Windows Forms 2.0 do it.
Can anyone please help ...?
Kindly regards,
Andreas Martin
|
|
|
|

|
Easy, clear and step by step. I can even work on it at ten minutes. Thank you very much!
|
|
|
|

|
I tried running myactivexf.htm on IE8 and IE7. It throws me error - Object doesnt support this property or method at line : MyactiveX1.LoadParameter(). in passParameter() funtion.
It makes sense from JS-point of view as this function is not defined in JS but in activeX control, but i m not able to figure out the problem. Can somebody please help ? I shall be obliged.
-Thank you
|
|
|
|

|
Hi,
I am trying to deploy ActiveX control which uses some custom dll libraries. It works fine when registered manually. But when I try to pack everything into CAB file and download install control from the web it fails.
How can I debug the problem why installation fails?
Do I have to do something specific to acompany my ocx contrl with the requred DLLs?
Thanks, great article BTW.
Mike
|
|
|
|

|
I am also having a similar issue with failure to install ActiveX control with supporting DLLs n CAB via web page. Does anyone have any suggestions on this?
Thanks, Ken
Best, Ken Claggett
|
|
|
|

|
I have fixed my problems. I pack CAB file ith the inf file like this:
[version]
; version signature (same for both NT and Win95) do not remove
signature="$CHICAGO$"
AdvancedINF=2.0
[Add.Code]
myactivex.ocx=myactivex.ocx
myactivex.inf=myactivex.inf
mylib.dll=mylib.dll
[myactivex.ocx]
file=thiscab
clsid={1CF26F28-9D05-40CC-9B61-1491925697C9}
RegisterServer=yes
FileVersion=1,0,0,4
[myactivex.inf]
file=thiscab
FileVersion=1,0,0,4
[mylib.dll]
file=thiscab
FileVersion=1,0,0,0
Also if your control is unsigned, you have to decrease your security settings in IE to "low", plus you ave to enable all the advanced settings related to ACtiveX in IE custom security level.
|
|
|
|

|
If using Windows Vista, Microsoft's Install for the ActiveX Control Pad, 'SetupPad.exe', fails to complete. Attempts to copy the installed files to Vista also do not work.
I switched back to using Windows XP and the ActiveX Control Pad installs and works with no apparent problems.
For those using Windows Vista who want to build the test page from scratch, there is a manual work-around:
1. Locate the MyActiveXCtrl.cpp file.
2. Locate the comment '// Initialize class factory and guid' where the GUID is defined in macro form.
3. Translate the macro form {0x--------, 0x----, 0x----, 0x--, 0x--, 0x--, 0x--, 0x--, 0x--, 0x--, 0x--}
to a GUID {xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx} (padding single digits with zeros):
For example:
Before: {0x33ddbb8d, 0x9db7, 0x4ad5, 0xa8, 0x3b, 0x38, 0x76, 0x3, 0xeb, 0x4f, 0x94}
After: {33DDBB8D-9DB7-4AD5-A83B-387603EB4F94}
4. Use the GUID (without curly braces} in place of the GUID given in the example shown in Figure 6.
For example:
After: CLASSID="CLSID:33DDBB8D-9DB7-4AD5-A83B-387603EB4F94"
Note: Make sure not to confuse MyActiveX.cpp with MyActiveXCtrl.cpp source files. Both have GUIDs, but only the GUID in MyActiveXCtrl correctly references the ActiveX control to use it within in a web page. Internet Explorer will not tell you the GUID is wrong -- it simply does nothing more than display a box with a red x.
=Dan=
|
|
|
|

|
you could use winrar to extract files from the setuppad.exe then launch setup.exe
|
|
|
|

|
Hello,
Thanks for a very good article.
I followed the article and succeeded to run the demo.
I tried to add a Calendar ActiveX control to the dialog and then it stopped running.
Any Ideas why?
I noticed that if I add the ActiveX control then the OnInitDialog is not called.
PLEASE help.
Many thanks
Uriel.
|
|
|
|

|
How to unregistering the ActiveX?
I need help!
今天没有时间,以后再写吧。
|
|
|
|

|
pku2009 wrote: I need help!
you most certainly do - maybe you should learn some manners first (like the words 'please' and 'thank you' !!)
does the standard command for registering/unregistering controls vis :-
regsvr32 /u <ocx file >
work ?
'g'
|
|
|
|

|
Garth J Lancaster,thank you !
I unregistering ActiveX just like this way
regsvr32 /u ;
But it doesn't work, Can you help me please?
今天没有时间,以后再写吧。
|
|
|
|

|
since you dont indicate what error you're getting, and a glance through some previous conversations below indicate that there may be a problem with the code itself internally calling DLLUnregisterServer or such, I guess there's two drastic options - find a registry cleaner tool that will delete the entries from the registry, or follow the blurb below (I found it somewhere on the net, cant remember where - both approaches are fraught with danger, but you may not have any choice )
"If you know what all the ProgIDs are, you can search through the HKCR hive for each one, writing down the CLSID for each. These keys need to be removed then. The CLSIDs can be used to search the HKCR\CLSID key. Each InprocServer32 subkey (for DLL/OCX components) has the registered path to the dll/ocx.
This can help you see if the component has been moved or removed.
The Typelib subkey contains a the LIBID that points to another key in
HKCR\TypeLib that would need to be removed. That just leaves any
interfaces. You would have to know the name of any interfaces to
search for in HKCR\Interface. OLE View will give you this info .."
'g'
|
|
|
|
|

|
tried to run it in the VS2005
get an error at line 318 ASSERT(::IsWindow(m_hWnd) || (m_pCtrlSite != NULL));
in winocc.cpp
anyhelp is appreciated
|
|
|
|

|
I assume you are getting this error when you try to load your ActiveX control in the ActiveX Control Pad?
Try rebuilding with the Release Version of the ActiveX control. Otherwise, you'll have to modify the winocc.cpp file to comment out the ASSERT line mentioned in your post and rebuild it to work around this bug.
|
|
|
|

|
this worked! thanks you so much
|
|
|
|

|
Or just IGNORE the assert.
|
|
|
|

|
Hi,
first of all thanks for such great article.
I am making an ActiveX Control to run in browser and i am able to make it successfully.
But i want it to communicate with SWF loaded in that html page.
Is it possible to do so?
If so then how?
Thanks in advance.
Manish Patel.
B.E. - Information Technology.
|
|
|
|

|
I need to retrieve the output parameter as raw 8-bit grayscale image (i.e byte array). How can i declare the parameter? Thanks in advance for any help.
|
|
|
|

|
Hello guys,
this example is working well in browsers prior to version 7.
on my vista box the IE says: "unknown vendor" and blocks the ActiveX Control.
i will use the ActiveX Control in intranet. is it still necessary to sign
the cab-file? how can i set the vendor.
got anyone ideas to solve the problem?
thanks
Leo
ps: don't be so picky of my englisch, i'm a german guy
|
|
|
|
 |
|
|
General News Suggestion Question Bug Answer Joke Rant Admin
Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.
|
This article is intended to help you get up to speed quickly with developing an ActiveX control. It will show you the basic concepts you need to know about ActiveX, such as methods, properties, and events, and how to communicate between an ActiveX control and a web page.
| Type | Article |
| Licence | |
| First Posted | 21 Jun 2006 |
| Views | 682,114 |
| Bookmarked | 378 times |
|
|