PC Review


Reply
Thread Tools Rate Thread

Area Chart not refreshing/updating properly

 
 
Ronald R. Dodge, Jr.
Guest
Posts: n/a
 
      13th Mar 2008
Excel 2002, SP3

I am actually using 2 charts to make up the apparence of 1 chart.

The first chart is the area chart so as I can get the goal line to go across
the entire plot area. (This is the chart that I'm having issues with)

The second chart is a line chart, which as an object, is over the top of the
area chart.

Both charts are setup as interpolated, so as lines are drawn from data point
to data point which other fields either being left as blank or having the
formula of "=NA()" are skipped on over as far as line drawing on the charts
is concerned.

Data Source of the area chart is setup as "Charts!B37:P37" (If I put in the
"Q" in place of the "P", line wouldn't go all the way to the right side of
the plot area)
Data Source of the line chart is setup as "Charts!B39:Q39" and
"Charts!B41:Q41"

The workbook (among others) is set to "Manual Calculation", which even when
using Shift-F9 manually, or using one of the following 2 VBA codes, the
chart does not update as would be expected:

Note, the m_chtProductionRateAreaChart is the ChartObject

m_chtProductionRateAreaChart.Chart.Refresh

Or

m_wshOperatorCharts.Calculate 'The worksheet the chart and data are on.

One more thing I have noticed. It seems after the VBA code is done with it
all, the Line Chart is selected, and I'm not sure if this is causing a
problem with the area chart or not.

If you will, for rows 37 through 41, each row is it's own row, no 2 rows are
merged together, but every 2 columns between B and S are merged together so
as to be able to have the data on the worksheet centered between the grid
lines on the chart while allowing for both 1st shift and 3rd shift data for
those same days showing side by side below on the worksheet. Yes, this
means data points are shown a bit to the left side rather than centered on
the line chart, but that will be dealt with later as that's just a cosmetic
issue, and I already have an idea how to resolve that issue This goal area
chart not adjusting properly is more of an issue cause it's gives off the
wrong perception by far.

The only way I so far have been able to find to get the chart to update
properly is to manually adjust the Y axis setting to either include or
exclude the tick label. However, by doing that, it would also mean that I
would have to reset the Left and Width properties of the PlotArea on the
chart. I'm already having to set these settings within VBA anyhow on my
chart objects so as they print out properly. The code is adjusting the
MaximumScale and MajorUnit properties on the Value Axis properly as
expected, just not refreshing the graph itself, which would be the values.

--
Thanks,

Ronald R. Dodge, Jr.
Production Statistician
Master MOUS 2000


 
Reply With Quote
 
 
 
 
Peter T
Guest
Posts: n/a
 
      13th Mar 2008
I didn't quite take all that in, why the two charts, and is the two charts
related to the update problem (I can't imagine why it should be).

It seems the second chart is merely to place a line over the main chart.
If(?) that's the intent why not place it on the main chart, various ways to
do that.

Regards,
Peter T

"Ronald R. Dodge, Jr." <(E-Mail Removed)> wrote in message
news:(E-Mail Removed)...
> Excel 2002, SP3
>
> I am actually using 2 charts to make up the apparence of 1 chart.
>
> The first chart is the area chart so as I can get the goal line to go

across
> the entire plot area. (This is the chart that I'm having issues with)
>
> The second chart is a line chart, which as an object, is over the top of

the
> area chart.
>
> Both charts are setup as interpolated, so as lines are drawn from data

point
> to data point which other fields either being left as blank or having the
> formula of "=NA()" are skipped on over as far as line drawing on the

charts
> is concerned.
>
> Data Source of the area chart is setup as "Charts!B37:P37" (If I put in

the
> "Q" in place of the "P", line wouldn't go all the way to the right side of
> the plot area)
> Data Source of the line chart is setup as "Charts!B39:Q39" and
> "Charts!B41:Q41"
>
> The workbook (among others) is set to "Manual Calculation", which even

when
> using Shift-F9 manually, or using one of the following 2 VBA codes, the
> chart does not update as would be expected:
>
> Note, the m_chtProductionRateAreaChart is the ChartObject
>
> m_chtProductionRateAreaChart.Chart.Refresh
>
> Or
>
> m_wshOperatorCharts.Calculate 'The worksheet the chart and data are on.
>
> One more thing I have noticed. It seems after the VBA code is done with

it
> all, the Line Chart is selected, and I'm not sure if this is causing a
> problem with the area chart or not.
>
> If you will, for rows 37 through 41, each row is it's own row, no 2 rows

are
> merged together, but every 2 columns between B and S are merged together

so
> as to be able to have the data on the worksheet centered between the grid
> lines on the chart while allowing for both 1st shift and 3rd shift data

for
> those same days showing side by side below on the worksheet. Yes, this
> means data points are shown a bit to the left side rather than centered on
> the line chart, but that will be dealt with later as that's just a

cosmetic
> issue, and I already have an idea how to resolve that issue This goal

area
> chart not adjusting properly is more of an issue cause it's gives off the
> wrong perception by far.
>
> The only way I so far have been able to find to get the chart to update
> properly is to manually adjust the Y axis setting to either include or
> exclude the tick label. However, by doing that, it would also mean that I
> would have to reset the Left and Width properties of the PlotArea on the
> chart. I'm already having to set these settings within VBA anyhow on my
> chart objects so as they print out properly. The code is adjusting the
> MaximumScale and MajorUnit properties on the Value Axis properly as
> expected, just not refreshing the graph itself, which would be the values.
>
> --
> Thanks,
>
> Ronald R. Dodge, Jr.
> Production Statistician
> Master MOUS 2000
>
>



 
Reply With Quote
 
Ronald R. Dodge, Jr.
Guest
Posts: n/a
 
      13th Mar 2008
The reason why not to put it onto the first chart, the first chart has the
line going from point to point (which is from center of category to center
of category). The second chart is the line that goes from the left edge to
the right edge, which is using the Area Chart as the option for it, as it's
an area chart that allows for lines to go from edge to edge within the plot
area.

--
Thanks,

Ronald R. Dodge, Jr.
Production Statistician
Master MOUS 2000
"Peter T" <peter_t@discussions> wrote in message
news:%(E-Mail Removed)...
>I didn't quite take all that in, why the two charts, and is the two charts
> related to the update problem (I can't imagine why it should be).
>
> It seems the second chart is merely to place a line over the main chart.
> If(?) that's the intent why not place it on the main chart, various ways
> to
> do that.
>
> Regards,
> Peter T
>
> "Ronald R. Dodge, Jr." <(E-Mail Removed)> wrote in message
> news:(E-Mail Removed)...
>> Excel 2002, SP3
>>
>> I am actually using 2 charts to make up the apparence of 1 chart.
>>
>> The first chart is the area chart so as I can get the goal line to go

> across
>> the entire plot area. (This is the chart that I'm having issues with)
>>
>> The second chart is a line chart, which as an object, is over the top of

> the
>> area chart.
>>
>> Both charts are setup as interpolated, so as lines are drawn from data

> point
>> to data point which other fields either being left as blank or having the
>> formula of "=NA()" are skipped on over as far as line drawing on the

> charts
>> is concerned.
>>
>> Data Source of the area chart is setup as "Charts!B37:P37" (If I put in

> the
>> "Q" in place of the "P", line wouldn't go all the way to the right side
>> of
>> the plot area)
>> Data Source of the line chart is setup as "Charts!B39:Q39" and
>> "Charts!B41:Q41"
>>
>> The workbook (among others) is set to "Manual Calculation", which even

> when
>> using Shift-F9 manually, or using one of the following 2 VBA codes, the
>> chart does not update as would be expected:
>>
>> Note, the m_chtProductionRateAreaChart is the ChartObject
>>
>> m_chtProductionRateAreaChart.Chart.Refresh
>>
>> Or
>>
>> m_wshOperatorCharts.Calculate 'The worksheet the chart and data are on.
>>
>> One more thing I have noticed. It seems after the VBA code is done with

> it
>> all, the Line Chart is selected, and I'm not sure if this is causing a
>> problem with the area chart or not.
>>
>> If you will, for rows 37 through 41, each row is it's own row, no 2 rows

> are
>> merged together, but every 2 columns between B and S are merged together

> so
>> as to be able to have the data on the worksheet centered between the grid
>> lines on the chart while allowing for both 1st shift and 3rd shift data

> for
>> those same days showing side by side below on the worksheet. Yes, this
>> means data points are shown a bit to the left side rather than centered
>> on
>> the line chart, but that will be dealt with later as that's just a

> cosmetic
>> issue, and I already have an idea how to resolve that issue This goal

> area
>> chart not adjusting properly is more of an issue cause it's gives off the
>> wrong perception by far.
>>
>> The only way I so far have been able to find to get the chart to update
>> properly is to manually adjust the Y axis setting to either include or
>> exclude the tick label. However, by doing that, it would also mean that
>> I
>> would have to reset the Left and Width properties of the PlotArea on the
>> chart. I'm already having to set these settings within VBA anyhow on my
>> chart objects so as they print out properly. The code is adjusting the
>> MaximumScale and MajorUnit properties on the Value Axis properly as
>> expected, just not refreshing the graph itself, which would be the
>> values.
>>
>> --
>> Thanks,
>>
>> Ronald R. Dodge, Jr.
>> Production Statistician
>> Master MOUS 2000
>>
>>

>
>



 
Reply With Quote
 
Ronald R. Dodge, Jr.
Guest
Posts: n/a
 
      13th Mar 2008
I haven't found a reason why for the issue, but I have found a work around
to the issue.

m_chtProductionRateAreaChart.Chart.SeriesCollection(1).Values =
Array(l_lngTotalGoal, l_lngTotalGoal)

Why I must use the Array method in order for the chart to update properly,
I'm not sure, but so be it. If that's how it has to be done, then that's
how it will be done.

--
Thanks,

Ronald R. Dodge, Jr.
Production Statistician
Master MOUS 2000
"Ronald R. Dodge, Jr." <(E-Mail Removed)> wrote in message
news:(E-Mail Removed)...
> Excel 2002, SP3
>
> I am actually using 2 charts to make up the apparence of 1 chart.
>
> The first chart is the area chart so as I can get the goal line to go
> across
> the entire plot area. (This is the chart that I'm having issues with)
>
> The second chart is a line chart, which as an object, is over the top of
> the
> area chart.
>
> Both charts are setup as interpolated, so as lines are drawn from data
> point
> to data point which other fields either being left as blank or having the
> formula of "=NA()" are skipped on over as far as line drawing on the
> charts
> is concerned.
>
> Data Source of the area chart is setup as "Charts!B37:P37" (If I put in
> the
> "Q" in place of the "P", line wouldn't go all the way to the right side of
> the plot area)
> Data Source of the line chart is setup as "Charts!B39:Q39" and
> "Charts!B41:Q41"
>
> The workbook (among others) is set to "Manual Calculation", which even
> when
> using Shift-F9 manually, or using one of the following 2 VBA codes, the
> chart does not update as would be expected:
>
> Note, the m_chtProductionRateAreaChart is the ChartObject
>
> m_chtProductionRateAreaChart.Chart.Refresh
>
> Or
>
> m_wshOperatorCharts.Calculate 'The worksheet the chart and data are on.
>
> One more thing I have noticed. It seems after the VBA code is done with
> it
> all, the Line Chart is selected, and I'm not sure if this is causing a
> problem with the area chart or not.
>
> If you will, for rows 37 through 41, each row is it's own row, no 2 rows
> are
> merged together, but every 2 columns between B and S are merged together
> so
> as to be able to have the data on the worksheet centered between the grid
> lines on the chart while allowing for both 1st shift and 3rd shift data
> for
> those same days showing side by side below on the worksheet. Yes, this
> means data points are shown a bit to the left side rather than centered on
> the line chart, but that will be dealt with later as that's just a
> cosmetic
> issue, and I already have an idea how to resolve that issue This goal
> area
> chart not adjusting properly is more of an issue cause it's gives off the
> wrong perception by far.
>
> The only way I so far have been able to find to get the chart to update
> properly is to manually adjust the Y axis setting to either include or
> exclude the tick label. However, by doing that, it would also mean that I
> would have to reset the Left and Width properties of the PlotArea on the
> chart. I'm already having to set these settings within VBA anyhow on my
> chart objects so as they print out properly. The code is adjusting the
> MaximumScale and MajorUnit properties on the Value Axis properly as
> expected, just not refreshing the graph itself, which would be the values.
>
> --
> Thanks,
>
> Ronald R. Dodge, Jr.
> Production Statistician
> Master MOUS 2000
>



 
Reply With Quote
 
 
 
Reply

Thread Tools
Rate This Thread
Rate This Thread:

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
Updating/Refreshing an embedded Microsoft Excel Chart Object JeffFarr Microsoft Powerpoint 1 28th Apr 2008 03:57 PM
Area Chart not refreshing/updating properly Ronald R. Dodge, Jr. Microsoft Excel Charting 1 13th Mar 2008 09:29 PM
Linked Access chart sometimes not updating properly =?Utf-8?B?Q2FsaG91blJhY2Nvb24=?= Microsoft Access Reports 1 31st Jan 2005 11:01 PM
How do I make the chart area equal in size to the plot area? =?Utf-8?B?UmVzb2x1dGlvbnBjMTU=?= Microsoft Excel Charting 3 4th Nov 2004 10:13 PM
Chart Object Not Updating Properly Scott Hakes Microsoft Access Reports 5 24th Jul 2003 05:24 PM


Features
 

Advertising
 

Newsgroups
 


All times are GMT +1. The time now is 04:20 PM.