Chartspace Conundrum

B

bulsatar

Hello Everyone,

I am having difficulty wrapping my arms around the chartspace and chchart
objects as they do not appear to behave the same as most objects. Here is my
question:

I have created a form with a default view as a pivotchart. What I would
like to do is save the formatting of the chart with an on open event. Then
let the user change anything that they want and with an on close event, set
the chart (or chartspace) back to the original formatting with the variable
set from the beginning.

So far I have tried setting a chartspace to a variable, a chart to a
variable, and cycling through the chart items and setting those to variable
to try and reformat that way (or even to just get the names of the items
being used). All of it has failed.

Thanks for the help, always appreciated

**using Access 2003 and OWC10 references
 
C

ChrisO

The graph object may be too complex to chase down each and every detail.
Perhaps it is simpler to just give the gofingerpokers a copy with which to
play.

Option Explicit
Option Compare Text

Public frmFormCopy As Access.Form


Sub ForTestOnly()

OpenFormCopy "My Graph Copy"

End Sub

' Please do NOT call this procedure from the original Form.
' We only want to open a copy of the original Form.
Public Sub OpenFormCopy(ByVal strFormCaption As String)

' Here, frmGraphOriginal is the
' literal name of the original Form.
Set frmFormCopy = New Form_frmGraphOriginal

With frmFormCopy
.Caption = strFormCaption
.Visible = True
End With

End Sub
 
C

ChrisO

A friend, Rainlover, let me know there is a simpler way to do it: -

Make an MDE file… :)
 

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