Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 1
Default Excel addin from C# - Trap excel events

Hi,
Am developing an addin for Excel using C#. When i try to trap the
SheetBeforeRightClick event(any event infact) of excel am getting "No such
interface supported" error.
Here is the code
public void OnStartupComplete(ref System.Array custom)
{
..................................
Excel.Application objExlApp = (Excel.Application)applicationObject;
objExlApp .SheetBeforeRightClick += new
AppEvents_SheetBeforeRightClickEventHandler(this.E xlRightClick_EvtHandler);
.................................
}
public void ExlRightClick_EvtHandler(object Sh,Excel.Range Target,ref bool
Cancel)
{
MessageBox.Show("Inside right click event handler");
}
Though it compiles, am getting "No such interface supported" error during
the runtime at the statement objExlApp .SheetBeforeRightClick += new
AppEvents_SheetBeforeRightClickEventHandler(this.E xlRightClick_EvtHandler);
..

Please help.
  #2   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 205
Default Excel addin from C# - Trap excel events

Hi Karthikeyan,

Am developing an addin for Excel using C#. When i try to trap the
SheetBeforeRightClick event(any event infact) of excel am getting "No such
interface supported" error.


You're more likely to get a helpful response if you post your question in the
public.vsnet.vstools.office newsgroup.

Regards

Stephen Bullen
Microsoft MVP - Excel

Professional Excel Development
The most advanced Excel VBA book available
www.oaltd.co.uk/ProExcelDev


Reply
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules

Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
How to trap KeyDown Events For Worksheets ? Adrian[_7_] Excel Programming 1 August 3rd 04 11:00 AM
Temporary storage, Addin events Phil Bewig Excel Programming 4 February 14th 04 08:45 PM
Remove Excel AddIn from AddIn List !! Help carl Excel Programming 2 December 8th 03 03:36 PM
Trap Excel events from VB pat Excel Programming 0 August 18th 03 11:01 PM


All times are GMT +1. The time now is 08:44 PM.

Powered by vBulletin® Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
Copyright ©2004-2024 ExcelBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Excel"