Link to home
Start Free TrialLog in
Avatar of jlcannon
jlcannon

asked on

Display graphic to website based on excel worksheet data

Hello all,
I am needing some code on how to display a certain image based on what data is filled in on a worksheet. What I want is I have basically a red dot, yellow dot and green dot small graphic that I want to use and on the website will be a table with a name in one cell and in the cell right next it I want to depending on the spreadsheet populate it with one of those images. Lets say Steve has 4 papers due and 1 turned in on his sheet will be a column for due papers and a column for turned in papers and then a pecent complete. well I want to use the number in percent complete to determin what color gife to use on the website. If less that 40 I use red between 41 and 60 yellow and 61-100 green. Does this make sense? I would love to have this done automatically as right now I manually change the colors based on going to look at the spreadsheet and then editing the webpage.
Avatar of dimmergeek
dimmergeek
Flag of United States of America image

Can you post a picture of the current graphic?
I have code I used for something similar that makes a horizontal bar chart (could be vertical) that shows x/y completed with percentages.
If the percentage is below or between certain thresholds the color of the bar changes.
My example is ASP gettiong data from Access, but it sounds like you've already figured out how to talk to Excel.
Avatar of jlcannon
jlcannon

ASKER

Currently it is all manual. When the spreadsheet is updated I take those numbers and then I open the html page and just change the number and manually change the picture reference so I was hoping to maybe use asp vb code to automate the process. I do know how to read data from excel and I just thought maybe there was an IF statement I could use to say "If cell b6 is <41 then this graphic if b6 >40 and <60 then this graphic if b6 >60 then this graphic.
ASKER CERTIFIED SOLUTION
Avatar of dimmergeek
dimmergeek
Flag of United States of America image

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial