PC Review


Reply
Thread Tools Rate Thread

Charting Filtered Data - Chart not updating unless workbook is re-opened

 
 
Jessica
Guest
Posts: n/a
 
      15th Apr 2004
Hi there,

I have an xy chart based upon data that will then be
filtered using an advanced filter.

The filter is applied, but the chart doesn't reflect the
filtered data unless the workbook is saved & reopened.
It's maddening.

A few notes:
* I do have another workbook where this works properly.
* This is XL 2000
* The filter itself is being applied using a macro
(details below)

It's killing me that I can make this work in one workbook
and I can't get it to work in two others.

Any ideas???
Thank you!
-Jessica

Here is the entirety of the code:
Private Sub CommandButton1_Click()
Application.ScreenUpdating = False
Application.Goto Reference:="calcs_page"
Application.Run "FilterData"
Sheets("Chart").Select
Application.ScreenUpdating = True
End Sub

and
Private Sub FilterData()

Range("filter_range").AdvancedFilter
Action:=xlFilterInPlace, CriteriaRange _
:=Range("Criteria"), Unique:=False

End Sub

 
Reply With Quote
 
 
 
 
Tushar Mehta
Guest
Posts: n/a
 
      15th Apr 2004
Is it possible you have calculation set to manual?

Have you tried Application.Calculate after the call to FilterData?

Also, you don't need the Application.Run "FilterData"
Just FilterData will suffice.

--
Regards,

Tushar Mehta
www.tushar-mehta.com
Business solutions leveraging technology
Microsoft Most Valuable Professional (MVP) 2000-2004

In article <29b601c4227f$a297e0f0$(E-Mail Removed)>,
(E-Mail Removed) says...
> Hi there,
>
> I have an xy chart based upon data that will then be
> filtered using an advanced filter.
>
> The filter is applied, but the chart doesn't reflect the
> filtered data unless the workbook is saved & reopened.
> It's maddening.
>
> A few notes:
> * I do have another workbook where this works properly.
> * This is XL 2000
> * The filter itself is being applied using a macro
> (details below)
>
> It's killing me that I can make this work in one workbook
> and I can't get it to work in two others.
>
> Any ideas???
> Thank you!
> -Jessica
>
> Here is the entirety of the code:
> Private Sub CommandButton1_Click()
> Application.ScreenUpdating = False
> Application.Goto Reference:="calcs_page"
> Application.Run "FilterData"
> Sheets("Chart").Select
> Application.ScreenUpdating = True
> End Sub
>
> and
> Private Sub FilterData()
>
> Range("filter_range").AdvancedFilter
> Action:=xlFilterInPlace, CriteriaRange _
> :=Range("Criteria"), Unique:=False
>
> End Sub
>
>

 
Reply With Quote
 
Guest
Posts: n/a
 
      15th Apr 2004
Alas, I have tried calculate to no avail.

But it must be something like that, since saving and re-
opening does the trick.

Is there anything like chart.calculate (I tried that)
Thanks!
-Jessica

>-----Original Message-----
>Is it possible you have calculation set to manual?
>
>Have you tried Application.Calculate after the call to

FilterData?
>
>Also, you don't need the Application.Run "FilterData"
>Just FilterData will suffice.
>
>--
>Regards,
>
>Tushar Mehta
>www.tushar-mehta.com
>Business solutions leveraging technology
>Microsoft Most Valuable Professional (MVP) 2000-2004
>
>In article <29b601c4227f$a297e0f0$(E-Mail Removed)>,
>(E-Mail Removed) says...
>> Hi there,
>>
>> I have an xy chart based upon data that will then be
>> filtered using an advanced filter.
>>
>> The filter is applied, but the chart doesn't reflect

the
>> filtered data unless the workbook is saved &

reopened.
>> It's maddening.
>>
>> A few notes:
>> * I do have another workbook where this works properly.
>> * This is XL 2000
>> * The filter itself is being applied using a macro
>> (details below)
>>
>> It's killing me that I can make this work in one

workbook
>> and I can't get it to work in two others.
>>
>> Any ideas???
>> Thank you!
>> -Jessica
>>
>> Here is the entirety of the code:
>> Private Sub CommandButton1_Click()
>> Application.ScreenUpdating = False
>> Application.Goto Reference:="calcs_page"
>> Application.Run "FilterData"
>> Sheets("Chart").Select
>> Application.ScreenUpdating = True
>> End Sub
>>
>> and
>> Private Sub FilterData()
>>
>> Range("filter_range").AdvancedFilter
>> Action:=xlFilterInPlace, CriteriaRange _
>> :=Range("Criteria"), Unique:=False
>>
>> End Sub
>>
>>

>.
>

 
Reply With Quote
 
Guest
Posts: n/a
 
      15th Apr 2004
Thanks to Jon Peltier, what I needed was

Application.CalculateFull

tra la la! Thank you! : D
>-----Original Message-----
>Alas, I have tried calculate to no avail.
>
>But it must be something like that, since saving and re-
>opening does the trick.
>
>Is there anything like chart.calculate (I tried that)
>Thanks!
>-Jessica
>
>>-----Original Message-----
>>Is it possible you have calculation set to manual?
>>
>>Have you tried Application.Calculate after the call to

>FilterData?
>>
>>Also, you don't need the Application.Run "FilterData"
>>Just FilterData will suffice.
>>
>>--
>>Regards,
>>
>>Tushar Mehta
>>www.tushar-mehta.com
>>Business solutions leveraging technology
>>Microsoft Most Valuable Professional (MVP) 2000-2004
>>
>>In article <29b601c4227f$a297e0f0$(E-Mail Removed)>,
>>(E-Mail Removed) says...
>>> Hi there,
>>>
>>> I have an xy chart based upon data that will then be
>>> filtered using an advanced filter.
>>>
>>> The filter is applied, but the chart doesn't reflect

>the
>>> filtered data unless the workbook is saved &

>reopened.
>>> It's maddening.
>>>
>>> A few notes:
>>> * I do have another workbook where this works properly.
>>> * This is XL 2000
>>> * The filter itself is being applied using a macro
>>> (details below)
>>>
>>> It's killing me that I can make this work in one

>workbook
>>> and I can't get it to work in two others.
>>>
>>> Any ideas???
>>> Thank you!
>>> -Jessica
>>>
>>> Here is the entirety of the code:
>>> Private Sub CommandButton1_Click()
>>> Application.ScreenUpdating = False
>>> Application.Goto Reference:="calcs_page"
>>> Application.Run "FilterData"
>>> Sheets("Chart").Select
>>> Application.ScreenUpdating = True
>>> End Sub
>>>
>>> and
>>> Private Sub FilterData()
>>>
>>> Range("filter_range").AdvancedFilter
>>> Action:=xlFilterInPlace, CriteriaRange _
>>> :=Range("Criteria"), Unique:=False
>>>
>>> End Sub
>>>
>>>

>>.
>>

>.
>

 
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
Charting different data formats in the same chart MILO Microsoft Excel Charting 2 8th May 2008 05:44 PM
Chart Activate event not triggered when workbook opened? kk_oop@yahoo.com Microsoft Excel Programming 0 2nd Sep 2006 02:37 AM
Charting Filtered Data BCullenward Microsoft Excel Charting 1 27th Oct 2005 11:19 AM
Charting cells with the same data in them to one chart bar Jason Spence Microsoft Excel Charting 1 27th Aug 2004 10:49 PM
Updating data via filtered form/query? Toni Microsoft Access Form Coding 0 9th Dec 2003 11:50 AM


Features
 

Advertising
 

Newsgroups
 


All times are GMT +1. The time now is 01:00 AM.