LinkBack Thread Tools Search this Thread Display Modes
Prev Previous Post   Next Post Next
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 70
Default Invoking Range.SpecialCells using IDispatch.Invoke

Hi,

I'm writing a method in XLL add-in for excel 2007 using the ComInterop to
call Range.SpecialCells using iDispatch.Invoke. but how I can pack the
XlCellType as Variant?
I've tried to provide the int value of the enum but it didn't work:

....
VariantInit(&lCellType);
lCellType.vt = VT_INT;
lCellType.intVal = -4123;
hr = AutoWrap(DISPATCH_METHOD,&lResult, pCellRef/*pionter to Range*/,
L"SpecialCells", &lCellType);

Any idea?

Regards,
Raja
 
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
SpecialCells method of Range class failed Sergei Emelyanenkov Excel Programming 3 June 16th 08 01:12 PM
Invert a range? - I wish SpecialCells(xlCellTypeHIDDEN) exist ... tskogstrom Excel Programming 1 November 26th 06 12:10 PM
specialcells(xlLastCell) and method global range error [email protected] Excel Programming 0 July 25th 06 09:51 PM
Invoking Excel via Getobject(From Access) to invoke Excel Macro Acie[_2_] Excel Programming 1 February 27th 04 07:56 PM
different IDispatch in event handler Dirk[_2_] Excel Programming 0 January 23rd 04 11:04 PM


All times are GMT +1. The time now is 11:20 AM.

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

About Us

"It's about Microsoft Excel"