Command Item doesn't work on menu or button

Add-in Express™ Support Service
That's what is more important than anything else

Command Item doesn't work on menu or button
The click event is never raised 
Juan Carlos Ruiz Pacheco




Posts: 40
Joined: 2010-05-11
Hello ,

I'm writing a solution for my client, all the functionalities works ok, the toolbar , the explorer bar and so on...

but when I add a command Item in the module the click event is never raised in the menu neither the button..

I have attached the debugger to IE and all my functionalities work ok, but if I want to debug the click event on the command Item nothing happens becasue Click event is never , never raised.

I'm using Windows 7 Ultimate X64 and IE 8.

Plz help me.
Juan Carlos Ruiz
Microsoft MVP Visual C#
Systems Engineer
MCP, OCA, OCP
Posted 18 May, 2010 08:24:13 Top
Juan Carlos Ruiz Pacheco




Posts: 40
Joined: 2010-05-11
On other hand, the icon associate with the command item is never displayed.

Today I'm doing test on another pc: Windows 7 Professional x86 and the problem still being the same...

But when I click the button the form I Call appeared for a few miliseconds and then disseapear again.

this is the event code:

Acerca_De acercade = new Acerca_De();
private void adxieCommandItem1_OnClick(object sender, object htmlDoc)
{
acercade.ShowDialog();
Thread.Sl eep(5000);
}[CODE]

acercade is a normal about form.
Juan Carlos Ruiz
Microsoft MVP Visual C#
Systems Engineer
MCP, OCA, OCP
Posted 18 May, 2010 08:58:07 Top
Sergey Grischenko


Add-in Express team


Posts: 7233
Joined: 2004-07-05
Hi Juan.

Did you enable the 'Allow active content to run in files on My Computer' option in IE?
Posted 19 May, 2010 08:04:05 Top
Juan Carlos Ruiz Pacheco




Posts: 40
Joined: 2010-05-11
I'm not,

what happens if that If I do the same code to handle click event in a menu the "about" form runs OK, but when I code the click event of the command item nothing happens ( command item bbutton or command item menu ).
Juan Carlos Ruiz
Microsoft MVP Visual C#
Systems Engineer
MCP, OCA, OCP
Posted 19 May, 2010 08:19:53 Top
Sergey Grischenko


Add-in Express team


Posts: 7233
Joined: 2004-07-05
The Commands collection adds buttons using IE SDK and the ADXIEMainMenu component uses subclassing to inject custom items to the IE main menu. These are two different approaches.
Posted 19 May, 2010 08:57:19 Top
Juan Carlos Ruiz Pacheco




Posts: 40
Joined: 2010-05-11
Sergey,
I've reviwed the IE settings and I have these option enabled:

http://img576.imageshack.us/i/active.png/

Uploaded with http://imageshack.us
Juan Carlos Ruiz
Microsoft MVP Visual C#
Systems Engineer
MCP, OCA, OCP
Posted 19 May, 2010 09:30:20 Top
Sergey Grischenko


Add-in Express team


Posts: 7233
Joined: 2004-07-05
Probably you also need to enable the "Enable third-party browser extensions" option.
Posted 19 May, 2010 10:11:57 Top
Juan Carlos Ruiz Pacheco




Posts: 40
Joined: 2010-05-11
:oops: where is this option located? at least in my language translation I can't find it. :oops:
Juan Carlos Ruiz
Microsoft MVP Visual C#
Systems Engineer
MCP, OCA, OCP
Posted 19 May, 2010 10:31:04 Top
Sergey Grischenko


Add-in Express team


Posts: 7233
Joined: 2004-07-05
It is located in the Browsing node of the Advance tab.
Posted 20 May, 2010 06:35:16 Top
Juan Carlos Ruiz Pacheco




Posts: 40
Joined: 2010-05-11
Hi, now I've seen..
but it is already checked :o
Juan Carlos Ruiz
Microsoft MVP Visual C#
Systems Engineer
MCP, OCA, OCP
Posted 20 May, 2010 09:05:57 Top