Display chart data on selected employees

M

malinchista

Greetings, Experts! (Sadly, I am not one of you)

While working at a company here in San Diego, a gal in our departmen
created a chart that could display company computer sales by model b
selecting the model from a combo box located right there on the chart.

For example, if the viewer selected "Model ABC123" from the combo box
the chart would automatically change to only reflect daily sales value
for that model only.

I don't know anything about visual basic, and that is what the chart'
macro is written in. Her macro looks up the models from a list o
models, then gathers the sales values from another sheet that contain
models with daily sales figures, then pastes it to another sheet tha
feeds the chart.

This is what her combo box code looks like:

===============================

Sub DropDown1_Change()

Dim intRow As Integer
Dim strItemNo As String
Dim intCounter As Integer ' Temp variable to b
used for incrementing

Worksheets("Model Data").Activate
intRow = Cells(1, 1).Value + 1
Worksheets("Model List").Activate
strItemNo = Cells(intRow, 1).Value
Worksheets("Model Data").Activate
Cells(3, 1).Value = strItemNo

Worksheets("CLIE Data").Activate

intCounter = 2
While ((Cells(intCounter, 1).Value <> strItemNo) And (intCounter
750))
intCounter = intCounter + 1
Wend
If intCounter = 750 Then
Sheets("Model by Model Chart").Select
MsgBox ("Model Data Not Found")
Else
Range(Cells(intCounter + 1, 4), Cells(intCounter + 13, 34)).Select
Selection.Copy
Sheets("Model Data").Activate
Cells(4, 4).Select
Selection.PasteSpecial Paste:=xlValues
Application.CutCopyMode = False
Sheets("Model by Model Chart").Select
End If

End Sub

===============

I want to create a similar chart that displays the daily sales total
by employee. Below is a snapshot of my worksheet. I want the viewe
to be able to select the employee's name from the combo box and displa
that employee's daily sales figures on the chart.

=======================================

ID Name 7 /1 7/2 7/3 7/5
116518 Christian, Jimbo $40 $20 $40
134211 Dokly, Ira $282 $120 $20
134283 Batty, Sheez $56 $145 $257
151001 Pray, Aye $748 $262 $526
===========

Respectfully request any tips or advice that you may have!

La Malinchist
 
P

Poh

Hi

Instead of doing the complicated way, i would like to
suggest to create a Stacked Column chart with all
employees' record. Make use of the AutoFilter feature,
when your viewer click to filter, chart will be updated
according to the filtered result.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top