PC Review


Reply
Thread Tools Rate Thread

Accessing a Shape on a Worksheet

 
 
excelthoughts@gmail.com
Guest
Posts: n/a
 
      21st Jun 2006
Hi,

I am attempting to access a Shape or Drawing Object on a worksheet to
chane its Onaction and ListFillRange.

In VBA, you did this:
sheet.DrawingObjects("name").OnAction= "action"
sheet.DrawingObjects("name").ListFillRange= "ListFillRange"

In C#:
I can get access to the Shape object via
sheet.Shapes.Item("name"), which gives me access to OnAction, but not
ListFillRange.

I have tried this too
//gets all Drawing Objects on sheet
Excel.DrawingObjects d =
(Excel.DrawingObjects)sheet.DrawingObjects(missing);
return d.Item(name);

The problem is that the returned object is a COM__Object, and it cannot
be cast to anything useful (like an OLEObject).

Help!!!!!!!!!!!!!!!
I have spent too long trying to figure this out.

 
Reply With Quote
 
 
 
Reply

Thread Tools
Rate This Thread
Rate This Thread:

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

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


Similar Threads
Thread Thread Starter Forum Replies Last Post
Is there a way to display the same shape on every worksheet? Bob Arnett Microsoft Excel Misc 3 28th Sep 2009 06:33 AM
How to Assign Worksheet Module to a Shape K Microsoft Excel Programming 1 23rd Oct 2008 05:09 PM
Shape/picture name in a worksheet neta Microsoft Excel Programming 1 29th May 2006 03:53 PM
Hyperlink a Visio shape to a worksheet tmi!tmi! Microsoft Excel Misc 4 1st Jun 2004 10:11 PM
Worksheet 'shape' (#columns by #rows) Peter Snell Microsoft Excel Misc 2 23rd Jan 2004 07:00 PM


Features
 

Advertising
 

Newsgroups
 


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