![]() |
Display image based on value/status
Hi,
I have a workbook with a "frontpage" containing dials (10 of them) to show the status of a number of Indicators, i.e. Off Track/Warning/On Track. I've successfully used the tip on http://www.mcgimpsey.com/excel/lookuppics.html to show the correct dial based on value/status in another worksheet, but how can I change it to be used in several cells in the same worksheet? The VB part on that page is "hard coded" (as far as I can understand - no VB expert) to only display the image in 1 specific cell. Also how would I go about centralizing the image in the cells? Code used - -------- Private Sub Worksheet_Calculate() Dim oPic As Picture Me.Pictures.Visible = False With Range("C7") <----------------- Hard coded cell ID. For Each oPic In Me.Pictures If oPic.Name = .Text Then oPic.Visible = True oPic.Top = .Top oPic.Left = .Left Exit For End If Next oPic End With End Sub ------- Many Thanks! - Max |
All times are GMT +1. The time now is 12:06 PM. |
Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
ExcelBanter.com