insert picture

  • Thread starter Thread starter Guest
  • Start date Start date
G

Guest

I'm trying to use excel 2000 vba to insert a picture based on a user's input of an employee id number. I'm tyring
picname = "c:\employee\pictures\" & empnumber & ".jpg

When i include this in the code it does not work. Any suggestions?
 
Hi,

i have just recoreded this macro

Sub Picinsert()
'
' Picinsert Macro
' Macro recorded 13/05/2004 by Simon
'
' Keyboard Shortcut: Ctrl+Shift+I
'
Range("C14:G24").Select
Selection.CopyPicture Appearance:=xlScreen, Format:=xlPicture
Sheets("Sheet1").Select
Range("D14").Select
ActiveSheet.PasteSpecial Format:="Picture (Enhanced Metafile)"
Link:=False _
, DisplayAsIcon:=False
End Sub

where Range is your selection to be a picture and sheets ("sheet1") i
the destination and Range("D14") is the destination cell to star
pasting from, as you didnt supply any code of your own its difficult t
see what you are trying to do...any way its all well beyond me i'e onl
just started at this stuff!

HTH

Simo
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Back
Top