Picture shows in excel if a threshold is hit - excel

I am creating an excel spreadsheet to track sales quota. I would like the spreadsheet to display a picture of fireworks when quota is hit. I don't know that much about macros, but good with formulas but that doesn't seem to help. Any ideas?

One way that I know it can be done:
1) Paste the picture of the fireworks in a cell (say A1) in a separate (preferably hidden sheet). Make sure to resize the cell (or the picture) so that the picture completely fits inside cell A1.
2) Define a named formula, maybe named "fireworks", which goes like:
=IF([Your condition for the fireworks to show],INDIRECT("[cell in which firework pic is]"),INDIRECT("[any blank cell"))
like for eg:
=IF(Sheet1!$C$6=TRUE,INDIRECT("Sheet2!$a$1"),INDIRECT("Sheet1!$M$8"))
3) Go to 'Insert' tab, click Object, click bitmap image. If paint or any image editor opens up just close it, so it inserts a blank image/object into the sheet. This image will have "=EMBED("Paint.Picture","")" in the formula bar. Replace this with a reference to our named formula, like =fireworks
4) Resize and reposition this image/object. When the condition is satisfied, the pic should pop up.

Related

Is possible to mirror a chart in another place?

I have a chart on one excel worksheet, and I want to show it in another worksheet without moving the original chart.
I do not want to copy and paste it, because if I modify the original chart (for example, changing his format), it will not be reproduced in the copy.
Is possible to hack it to show the chart in another page? Maybe a picture whose image is automatically taken from the original chart?
I frequently modify the original chart, and I have another worksheet where I watch many charts at once.
This can be done with a dynamic image, without VBA.
It will work best if the original chart is perfectly aligned with a range of cells.
select the range of cells behind the chart, for example A1:D10. You may want to give that range a name with the Name Manager, i.e. myChart, for convenience
on the Home ribbon, click the Copy dropdown and select "Copy as Picture"
accept the defaults "as shown on screen" and "picture" and hit OK
in the target worksheet (in the SAME workbook), select a cell and paste from the clipboard
select the pasted image and click into the formula bar. Enter the cell range you copied it from into the formula bar, e.g. =Sheet1!$A$1:$D$10, or, if you have set up a name, use that, like =myChart
The image is now dynamic and will reflect whatever content is showing in the specified cell range. If you resize the original cells, the dynamic image will distort.
Be aware that you are not creating an image of the actual chart, but only of the cells that the chart covers. If you move the chart away from the range, then it will not be visible in the dynamic image.
That's why this technique works best if the chart is perfectly aligned with a range of cells.
More details about this technique, using it to create combination Sparklines is in this article written in 2011, but everything still applies.

How to find out which cells are pulling data from another sheet

I want to find out exactly which cells in my excel workbook are pulling data from another sheet inside the same workbook. Is there a way to do this?
Yes, there is an easy way to do it if you don't have a lot of cells.
Click the cell you want to check, then go to "Formulas" -> "Trace Precedents". [you need to do it for each cell :(, so that's the disadvantage]. You might need to click several times for each cell.
Notice the difference in my picture. The cells in the range B5:B13 has a formula linked to an external source (another worksheet or another workbook, shown as a little mini table), while the cell B15 who has a blue arrow, is linked to cell E14 on the same worksheet!
If you want to know which linkage (which source cell it's linked to), klick on the arrow and you should see this window;
If there are a massive amount of cells, I would give this VBA code a try:
VBA to list all external links together with the cells containing the links

Excel linked pictures change scale after copying sheet

I have created a dashboard sheet by using the camera tool to paste graphs from other sheets as linked picture in the dashboard sheet. When I copy the whole sheet (by right clicking the sheet tab) and paste it as a new sheet in the same workbook, the scale of my graphs reverts to the scale of the original graph. This results in the whole dashboard being distorted with overlapping graphs.
What did I do already:
googled it
I have tried numerous combinations of "Lock aspect ratio" and "Relative to original picture size" under Size, and "Move but don't size with cells", "Don't move or size with cells" under Properties.
It looks like copying every object one by one works, but if you copy the whole sheet it distorts everything.
Another guy posted exactly the same problem here but he didn't get any answer.
It would be great if someone is able to help me with this annoying problem.
Johan
I had the same problem - when copying a worksheet with a paste link picture and it loses scale
I got around it by creating a text box in the origin square and then putting the picture into the text box
Then when copying the sheet with the linked picture file it does not lose scale
I found a way around
Create a chart object (delete all chart related graphics = empty area).
Set width, height of chart object equal to your linked picture.
Click your linked picture to select and copy (Ctrl+C) then unselect.
Click chart object to select and paste (Ctrl+P)
DONE!
Now, your linked picture size won't change anymore

Excel "Insert shapes" Color change based on cell value

Anyone knows how to Change the color of Shapes("Insert-> Shapes") based on the value of a cell. i could do this with the help of macro. but i now need the same to be done without the help of macro.
Kindly share the formula if anyone can do this.
thanks.
Example how to show the picture of a named range in a ActiveX image control:
Open Excel with a empty Worksheet Sheet1.
Write 0 in A1.
Create a named range using the Name Manager http://office.microsoft.com/en-us/excel-help/define-and-use-names-in-formulas-HA010147120.aspx#BMmanage_names_by_using_the_name_manage
to do so:
open Name Manager
click New
Name= Image
Refers To= =INDEX(Sheet1!$E:$E,Sheet1!$A$1*4+1):INDEX(Sheet1!$E:$E,Sheet1!$A$1*4+4)
OK
close Name Manager
now:
Take a ActiveX Image Control from Developer tab
(http://office.microsoft.com/en-us/excel-help/show-the-developer-tab-HA101819080.aspx)
Controls and put it in the Worksheet.
Overwrite the formula =EMBED(...) in the formula bar with =Image
(the name of the named range). Now, if you change the value in Sheet1!A1,
you should see the cells E[n]:E[m] with n=A1*4+1 and m=A1*4+4 as
picture in the Image Control. Try it by putting values in E1:E20
and change A1.
Now, if you place different shapes over E1:E4, E5:E8, E9:E12,... you
see them in the Image Control by changing the value in A1.
Edit April 2019:
This works using Excel 2007. It does not work in later Excel versions because the ActiveX Image control does not more accept cell ranges as source.
Just tested in Excel 365:
First do the same steps as above but then in last step
now:
Copy four cells of one column (A1:A4 for example) into the clipboard. It is not important from where the cells are coming.
In the sheet where the image shall appear do Home -> Paste -> Linked Picture. A picture showing the copied cells is pasted. And the formula bar shows the formula =Sheet1!$A$1:$A$4 for example.
Overwrite the formula in the formula bar with =Image (the name of the named range). Now, if you change the value in Sheet1!A1, you should see the cells E[n]:E[m] with n=A1*4+1 and m=A1*4+4 as picture in the pasted picture. Try it by putting values in E1:E20 and change A1.
Now, if you place different shapes over E1:E4, E5:E8, E9:E12,... you see them in the pasted picture by changing the value in A1.

How to hide a picture in an Excel cell?

My excel sheet has many rows. Each row is a project. I want to put a picture into a cell and I hope the picture will be very small when I am NOT click on it. In other words, I don't want to see the full size picture until I click on the cell? How I could do that? Thanks
It is possible to insert a picture into a cell's comment. The picture will not appear unless you hover over the commented cell. See this previous SO answer.

Resources