Home |
Search |
Today's Posts |
#1
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
I've spent about 5 hours tonight trying to find out how to insert a picture
into a cell using VB.NET. It turns out I was finding code which (ALMOST) works but Intellisense kept telling me that ActiveSheet does not have a Pictures method. When, in desperation, I finally decided to just try to run the code despite the Intellisense warning, it worked!, ALMOST. The almost part is that the picture ends up in the wrong cell. I use the following code ... objSheet.Range("A1").Select() objSheet.Pictures.insert("e:\temp\jpeg samples\s_01.jpg") but the picture ends up in row 4, column B. I've tried other arguments to the Range method but the picture always ends up in row 4, column B. Note that this is not VBA. I am using VB.NET and an Interop Assembly (Microsoft Excel 12.0 Object Library / Imports Excel = Microsoft.Office.Interop.Excel). I'd sure appreciate any thoughts anyone might have. The next thing that I'll have to do is to get the picture sized correctly, if you'd care to offer any help in that area. Thanks, Bob |
Thread Tools | Search this Thread |
Display Modes | |
|
|
![]() |
||||
Thread | Forum | |||
how do I associate an inserted picture with its row? | Excel Discussion (Misc queries) | |||
Copy from one worksheet to another is inserted into wrong cell | Excel Discussion (Misc queries) | |||
Inserted picture name | Excel Programming | |||
picture 34 was inserted by excel? | Excel Discussion (Misc queries) | |||
How to write in cell, in Excel, under the inserted picture. Pictu. | Excel Discussion (Misc queries) |