Home |
Search |
Today's Posts |
#1
Posted to microsoft.public.excel.misc
|
|||
|
|||
Insert Picture
when I use, ActiveSheet.Pictures.Insert(stringVariable).Select , I receive the following error. Runtime error '1004': Unable to get the Insert property of the Pictures class If I use, ActiveSheet.Pictures.Insert("c:\mypicture.jpg").se lect, it works fine. ?????? -- maximus73 ------------------------------------------------------------------------ maximus73's Profile: http://www.excelforum.com/member.php...o&userid=25877 View this thread: http://www.excelforum.com/showthread...hreadid=522865 |
#2
Posted to microsoft.public.excel.misc
|
|||
|
|||
Insert Picture
I'd guess that your stringVariable doesn't contain a real filename--just a
typo??? I'd check first: Dim StringVariable As String Dim testStr As String Dim myPict As Picture StringVariable = "C:\asdf.jpg" testStr = "" On Error Resume Next testStr = Dir(StringVariable) On Error GoTo 0 If testStr = "" Then MsgBox StringVariable & " doesn't exist" Else Set myPict = ActiveSheet.Pictures.Insert(StringVariable) End If maximus73 wrote: when I use, ActiveSheet.Pictures.Insert(stringVariable).Select , I receive the following error. Runtime error '1004': Unable to get the Insert property of the Pictures class If I use, ActiveSheet.Pictures.Insert("c:\mypicture.jpg").se lect, it works fine. ?????? -- maximus73 ------------------------------------------------------------------------ maximus73's Profile: http://www.excelforum.com/member.php...o&userid=25877 View this thread: http://www.excelforum.com/showthread...hreadid=522865 -- Dave Peterson |
Reply |
Thread Tools | Search this Thread |
Display Modes | |
|
|
Similar Threads | ||||
Thread | Forum | |||
Insert Picture from dropdown selection | New Users to Excel | |||
Is it possible to insert a picture using formulas? | Excel Worksheet Functions | |||
How to insert a picture in the Footer (not the Header) in Excel 20 | Excel Worksheet Functions | |||
insert picture | Excel Discussion (Misc queries) | |||
Challenging Charting | Charts and Charting in Excel |