PDA

View Full Version : Solved: Charts & Ranges



Nocturne
03-17-2009, 05:12 PM
I have a question about ranges. I have a spreadsheet with a chart. The chart updates as needed, but my problem is this, how do you create a range without using the selection method. In my workbook, when I update the chart I have to activate the sheet with the information and then reactivate the chart sheet. Is there anyway to do this, it is more annoying then anything.

mdmackillop
03-17-2009, 05:53 PM
Can you post a sample workbook so we can see how they are linked? How do you update the chart? I would have thought this automatic.

Bob Phillips
03-17-2009, 06:05 PM
Just set the Source data of the chart to the range in question - directly.

Nocturne
03-18-2009, 04:52 AM
I would post the workbook, but I don't know how.

mdmackillop
03-18-2009, 05:48 AM
Use Manage Attachments in the Go Advanced reply section

Nocturne
03-19-2009, 02:25 PM
Here is the workbook.

Bob Phillips
03-19-2009, 02:59 PM
So, what's the issue?

Nocturne
03-19-2009, 03:00 PM
The issue is I do not like it flipping pages. I would like for it to stay on the chart when I ask for a date range for the chart.

Bob Phillips
03-19-2009, 03:04 PM
Sorry, all I see is an empty chart, and you explanation explains nothing to me.

Nocturne
03-19-2009, 04:03 PM
On the front page (sheet1) of the workbook is wordart items, they call subs just as a command button would. When you click on the one that says chart then it opens a userform that will initiate the population of the chart based on the date range. After you click of then it will activate the usage page while selecting the cells for the date range then it activates the chart page. My question is can I designate a range without using this Selection.Resize(Selection.Rows.Count + 1).Select ?

Nocturne
03-19-2009, 04:05 PM
It is similiar to lights blinking to me. I would like to stay on whatever sheet I wish without needing to activate another sheet in the workbook.

mdmackillop
03-19-2009, 04:16 PM
Private Sub cmdok_Click()
Application.ScreenUpdating = False
Call tempdemand
Application.ScreenUpdating = True
End Sub

mdmackillop
03-19-2009, 04:21 PM
BTW,
You should really use Option Explicit in each code module and Dim all your variables. With 15 module sheets having no descriptions, no comments and meaningless Sub names, you're storing up problems in maintaining this in the future.

Nocturne
03-24-2009, 04:50 AM
Thanks for the help. The screen updating did it for me. Thanks again.

Aussiebear
03-24-2009, 04:57 AM
BTW,
You should really use Option Explicit in each code module and Dim all your variables. With 15 module sheets having no descriptions, no comments and meaningless Sub names, you're storing up problems in maintaining this in the future.

That's very good advice MD.