Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations SkipVought on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Problems Updating Graph

Status
Not open for further replies.

microtoolmaker

Technical User
Feb 21, 2000
17
0
0
US
I have a graph embedded in a form that plots a values from calculated fields in a query. The graph needs to be updated after each new record is added. I do not want to link fields since that isolates the graph view to the current record only.<br>
Doing a requery does not help. The only way I've seen this graph update is to close and re-open the form...<br>
<br>
Can anyone help me with this?
 
My Friend, you can try to disvinculate the OLE from the graph's base query setting the RowSource property to &quot;&quot; and revinculate it. <br>
<br>
Write the following code at any event procedure that is executed when the new record is added.<br>
<br>
'disvinculate<br>
Forms[Your_Form]![Your_OLE].RowSource = &quot;&quot;<br>
Forms[Your_Form]![Your_OLE].Requery<br>
<br>
'if necessary insert code to update tables or queries <br>
'used in the Graph_Query_Base <br>
<br>
'revinculate <br>
Forms[Your_Form]![Your_OLE].RowSource = &quot;Graph_Query_Base&quot;<br>
Forms[Your_Form]![Your_OLE].Requery<br>

 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top