Home |
Search |
Today's Posts |
|
#1
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
hi experts,
how to insert image from resource file. |
#2
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
Hi VJ,
Try something like: '============= Public Sub Tester() Dim myPath As String Dim MyImage As String my Path = "C:\Documents and Settings\VJS\" _ & "My Documents\My Pictures\" MyImage = "YourImage Name.jpg" ActiveSheet.Pictures.Insert (myPath & MyImage) End Sub '<<============= --- Regards, Norman "vj5" wrote in message ... hi experts, how to insert image from resource file. |
#3
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
hi experts
thanks for reply my problem is that i can't save image in a file and can't give path of image file. i have to take image from resource file only. is there ANY possibility to do the same? "Norman Jones" wrote: Hi VJ, Try something like: '============= Public Sub Tester() Dim myPath As String Dim MyImage As String my Path = "C:\Documents and Settings\VJS\" _ & "My Documents\My Pictures\" MyImage = "YourImage Name.jpg" ActiveSheet.Pictures.Insert (myPath & MyImage) End Sub '<<============= --- Regards, Norman "vj5" wrote in message ... hi experts, how to insert image from resource file. |
#4
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
Whilst you can certainly use the API to LoadLibrary/LoadBitmap etc in VBA,
none of Excel's objects (natively) expose handles or DCs, so I can't see what you would do with results. Save the pic to file, insert, then delete ? NickHK "vj5" wrote in message ... hi experts, how to insert image from resource file. |
#5
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
thanks for reply
my problem is that i can't save image in a file and can't give path of image file. i have to take image from resource file only. is there ANY possibility to do the same? "NickHK" wrote: Whilst you can certainly use the API to LoadLibrary/LoadBitmap etc in VBA, none of Excel's objects (natively) expose handles or DCs, so I can't see what you would do with results. Save the pic to file, insert, then delete ? NickHK "vj5" wrote in message ... hi experts, how to insert image from resource file. |
#6
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
Take it from the resource file, save to file, insert, delete the file.
Why can't you save to file temporarily ? NickHK "vj5" wrote in message ... thanks for reply my problem is that i can't save image in a file and can't give path of image file. i have to take image from resource file only. is there ANY possibility to do the same? "NickHK" wrote: Whilst you can certainly use the API to LoadLibrary/LoadBitmap etc in VBA, none of Excel's objects (natively) expose handles or DCs, so I can't see what you would do with results. Save the pic to file, insert, then delete ? NickHK "vj5" wrote in message ... hi experts, how to insert image from resource file. |
#7
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
if user don't have save permission than it will fails thats why i can't
save it on machine. "NickHK" wrote: Take it from the resource file, save to file, insert, delete the file. Why can't you save to file temporarily ? NickHK "vj5" wrote in message ... thanks for reply my problem is that i can't save image in a file and can't give path of image file. i have to take image from resource file only. is there ANY possibility to do the same? "NickHK" wrote: Whilst you can certainly use the API to LoadLibrary/LoadBitmap etc in VBA, none of Excel's objects (natively) expose handles or DCs, so I can't see what you would do with results. Save the pic to file, insert, then delete ? NickHK "vj5" wrote in message ... hi experts, how to insert image from resource file. |
#8
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
You can always save it to
C:\Documents and Settings\<Current User\Application Data\<Your Company\ Or the Temp folder. You must be able to save it somewhere. NickHK "vj5" wrote in message ... if user don't have save permission than it will fails thats why i can't save it on machine. "NickHK" wrote: Take it from the resource file, save to file, insert, delete the file. Why can't you save to file temporarily ? NickHK "vj5" wrote in message ... thanks for reply my problem is that i can't save image in a file and can't give path of image file. i have to take image from resource file only. is there ANY possibility to do the same? "NickHK" wrote: Whilst you can certainly use the API to LoadLibrary/LoadBitmap etc in VBA, none of Excel's objects (natively) expose handles or DCs, so I can't see what you would do with results. Save the pic to file, insert, then delete ? NickHK "vj5" wrote in message ... hi experts, how to insert image from resource file. |
Reply |
Thread Tools | Search this Thread |
Display Modes | |
|
|
![]() |
||||
Thread | Forum | |||
insert an image based on a cell value | New Users to Excel | |||
insert image to the cells | New Users to Excel | |||
conditionally insert image | Excel Programming | |||
how do I insert image in a comment? | Excel Discussion (Misc queries) | |||
Insert Image on a form | Excel Programming |