How do i insert a picture in merged cels, with autom. resizing ?
Sub AA_InsertPicture()
Dim rng As Range, pic As Picture
Set rng = Range("B2").MergeArea
rng.Select
Set pic = ActiveSheet.Pictures.Insert( _
"C:\Documents and Settings\OgilvyTW\" & _
"My Documents\My Pictures\Sample.jpg")
pic.Top = rng.Top
pic.Left = rng.Left
pic.Width = rng.Width
pic.Height = rng.Height
End Sub
worked for me.
--
Regards,
Tom Ogilvy
"Sven Ghyselinck" wrote:
I want to insert a picture (no matter what size) into merged celles. So if
the picture in imported, it must be resized automatic to fit into the merged
celles.
Thanks for the help.
|