Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Chriss Miller on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Can you paste an image into a cell in excel?

Status
Not open for further replies.

hendrang

Programmer
May 20, 2006
11
US
Hi,

I have been searching the answer for this for awhile. I'm not sure if there is actually a way to paste an image into a cell (along with the text if there is one). By pasting here I mean copying image from internet for example and pasting it (no directory). Can someone help me with this? Thank you
 


Hi,

Technically, you paste or insert an object into a sheet, not a cell.

Have you tried doing it? BTW, turn on your macro recorder when you paste or insert and observe the generated code.

Skip,

[glasses] [red]Be Advised![/red] A chicken, who would drag a wagon across the road for 2 cents, is…
POULTRY in motion to PULLET for a PALTRY amount! [tongue]
 
I did try pasting in into a sheet. However, that's not what I want. The image still "hanging" freely in the sheet. Hence, I tried to find a way to paste it into a cell. Or if someone knows a better trick to do this, please share it with me...pleaseeeee.....:D
 
Having done quite amount of search, I personally think that there is no way to do this in excel. Can someone confirm this? If this is true, what program will be the best?
 


It is indeed on the sheet

. Try setting the Format/Picture - Properties tab -- Move & Size with cell.

Skip,

[glasses] [red]Be Advised![/red] A chicken, who would drag a wagon across the road for 2 cents, is…
POULTRY in motion to PULLET for a PALTRY amount! [tongue]
 


" what program will be the best? "

Best for what? What are you trying to accomplish? Sure, there are some applications that are more suited to specific requirements. What are your requirements?

Skip,

[glasses] [red]Be Advised![/red] A chicken, who would drag a wagon across the road for 2 cents, is…
POULTRY in motion to PULLET for a PALTRY amount! [tongue]
 
What I am creating is a test plan table. In the table, there will be some screenshots involved. Any suggestion? Thanks in advance
 


So what's wrong with Excel? Under what conditions are these objects moving?

Skip,

[glasses] [red]Be Advised![/red] A chicken, who would drag a wagon across the road for 2 cents, is…
POULTRY in motion to PULLET for a PALTRY amount! [tongue]
 
What about using tables in Word?
I have done many test plans in Word with screen shots and text associated with the screenshots in tables, works very well.
 
SkipVought:

There is nothing wrong with excel. I create a template for my test plan and everything is great, except this screenshot image that bothers me. I'm trying to find a way for that screenshot to be in the cell. I know word can do that, but I'm not sure about excel.


Ettienne:

Word works well when it comes to screenshot. Can word do calculation too? As far as I know, word cannot...
 


What about the screenshot image bother you?

Word can do simple calculations in a table.

Skip,

[glasses] [red]Be Advised![/red] A chicken, who would drag a wagon across the road for 2 cents, is…
POULTRY in motion to PULLET for a PALTRY amount! [tongue]
 
The thing that bothers my mind is about me unable to put the screenshot in the cell. I still want to stick with excel since as you know excel can calculate number of conditions for example. I can also use formula.
 


Did you try looking at the object properties?

Skip,

[glasses] [red]Be Advised![/red] A chicken, who would drag a wagon across the road for 2 cents, is…
POULTRY in motion to PULLET for a PALTRY amount! [tongue]
 
Hendrang, what you are being asked to do is try and learn a little something about the properties of the pasted picture object. You can size it and make it appear to be "in" the cell by setting it's properties accordingly.
However I use a slightly different method using a comment and the fill properties of the comment background as follows...
Code:
Set cmt = ActiveCell.AddComment
                    cmt.Text Text:=""
                        With cmt.Shape
                                .Fill.UserPicture "\path\imagename.jpg"
                                .Width = 450
                                .Height = 350
                        End With
                    cmt.Visible = True

Sean Murphy
Call Centre Analyst
IAG New Zealand
 
hi smurfyIAG, what I'm trying to ask is to paste an image (i.e screenshot) that I copied from a website for example. Probably the best way to explain this is by imagining a user that has a test plan in front of him. He then found a screenshot from some place...copy it and now he wants to paste it into the test plan. He wants it to be in the cell (not the sheet) and probably continue typing. There is NO directory where the image is stored involved at all. I hope my question is clear now. I have been searching for answer too, but no luck.
 
As you have already been told several times:
you CANNOT paste an image INTO a cell
you can ONLY paste ONTO the sheet
You can make the image LOOK like it is sitting in a cell by sizing it appropriately and setting some basic properties



Rgds, Geoff

We could learn a lot from crayons. Some are sharp, some are pretty and some are dull. Some have weird names and all are different colours but they all live in the same box.

Please read FAQ222-2244 before you ask a question
 
Sorry for the misunderstanding. I thought people want to know exactly what I was doing and might give me a way around this. My bad....
 
hendrang,

Geoff has posted your answer. I think he understands exactly what you are trying to do. You explained what you were doing, and you were answered.

You want to put the image into a cell.

You can not put an image into a cell.

Other than making it LOOK like it is in the cell, there IS no way around this. You can want a way around it all you want, but implying people are not listening is inaccurate.

smrfyIAG had a good suggestion. Would that work for you?

Lastly, you are mentioning two things. You want to put the image into a cell. You can't.

But you also mention calculating - which is why you want to do this in Excel. Is there any connection??? What is the connection between putting an image in a cell, and calculating anything?

Gerry
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top