Hi, Duane
Thanks for the reply. I was running this code in
Report_Open event. I will try the Detail_Format event.
But I don't see why it should not work for Report_Open
event. As a matter of fact, I try to print out all the
properties of graph3 in the debug window, with this code
Dim prp As Property
For Each prp In Me.Graph3.Properties
Debug.Print Me.Graph3.name; " "; prp.name; "="; prp.Value
Next prp
The output in the debug window I got is:
Graph3 EventProcPrefix=Graph3
Graph3 Name=Graph3
Graph3 ControlType= 113
Graph3 SizeMode= 0
Graph3 OLEClass=Microsoft Graph 2000 Chart
Graph3 Item=
Graph3 DisplayType=False
Graph3 Verb= 0
Graph3 OLEType= 3
Graph3 OLETypeAllowed= 2
Graph3 SourceObject=
Graph3 Class=MSGraph.Chart.8
Graph3 SourceDoc=
Graph3 SourceItem=
Graph3 Visible=True
Graph3 Left= 360
Graph3 Top= 240
Graph3 Width= 12241
Graph3 Height= 7740
Graph3 BackStyle= 1
Graph3 BackColor= 16777215
Graph3 SpecialEffect= 0
Graph3 BorderStyle= 1
Graph3 OldBorderStyle= 1
Graph3 BorderColor= 0
Graph3 BorderWidth= 0
Graph3 BorderLineStyle= 0
Graph3 ShortcutMenuBar=
Graph3 Section= 0
Graph3 Tag=
Notice here the rowsource, rowsourcetype, linkchild, etc.
are not even listed. I don't know why. But if the
rowsource is not even listed, no wonder I can not set its
value. Neverthless, in the online help of MS Access on
RowSource and RowSourceType, it was clearly stated that
RowsSource IS a chart control property and CAN be set by
Visual Basic Code.
Could you give me further guidence?
Best Regards,
Ge