Google Groups no longer supports new Usenet posts or subscriptions. Historical content remains viewable.
Dismiss

Disconnect Charf from Data

8 views
Skip to first unread message

rupert

unread,
Apr 3, 2002, 10:11:43 AM4/3/02
to
I am trying to create charts using temporary data. I would
like to be able to clear the data from the worksheet after
the chart is created. I have tried the code to set the
series values/xvalues to the itself, but I always recieve
a '1004 Unalbe to set (values/xvalues) of Series object'
error.
oCurrSeries.Name = oCurrSeries.Name
oCurrSeries.Values = oCurrSeries.Values
oCurrSeries.XValues = oCurrSeries.XValues

I have tried a variety of variations of the code, but no
luck. The chart I am working with has contains 3 series, 2
are xlArea, third is a xlLineMarker. I am writing the
program for this using XL2000 & VB5. If anyone has any
suggestions, I would apperciate it.

John Walkenbach

unread,
Apr 3, 2002, 11:10:28 AM4/3/02
to
That code will work fine as long as the chart series doesn't have too many
data points. The problem is that there is a limit to the length of the
SERIES formula. It's likely that you exceeded that limit.

Try doing it manually: Select the series, then click in the formula bar.
Press F9 to convert the ranges in the SERIES formula to arrays. If you get
an error, that means you have too many data points.

Another option is to convert the chart to a graphic object.

John Walkenbach
For Excel tips, macros, & downloads...
http://j-walk.com/ss


"rupert" <rup...@sciinc.com> wrote in message
news:a50e01c1db21$dd2aadd0$b1e62ecf@tkmsftngxa04...

Jon Peltier

unread,
Apr 3, 2002, 12:24:16 PM4/3/02
to
Rupert -

I worked out a VBA routine that truncates all those excess digits in the chart
data. Look for a link to "Delink Chart from Data" on my charting web page:

http://www.geocities.com/jonpeltier/Excel/Charts/index.html

If your problem is too many data points, as John has suggested, this routine
will extend the number of points you can have before the routine bombs.

- Jon
_______

In article <#KFDsny2BHA.2236@tkmsftngp02>, jo...@j-walk.com says...

rupert

unread,
Apr 3, 2002, 3:32:01 PM4/3/02
to
Thanks for you help. Now that I understand why I am
getting the error, I can find ways to work around it. The
only problem I see is that the XValues of my graph is a
date for every week over the last 2 years (which gives me
+105 5 digigt values, right off the bat). Thanks again for
your help, I will see what I can do about trimming the
data.

>-----Original Message-----
>Rupert -
>
>I worked out a VBA routine that truncates all those
excess digits in the chart
>data. Look for a link to "Delink Chart from Data" on my
charting web page:
>
>http://www.geocities.com/jonpeltier/Excel/Charts/index.htm
l
>
>If your problem is too many data points, as John has
suggested, this routine
>will extend the number of points you can have before the
routine bombs.
>
>- Jon
>_______
>

>In article <#KFDsny2BHA.2236@tkmsftngp02>, john@j-

>.
>

0 new messages