×
INTELLIGENT WORK FORUMS
FOR ENGINEERING PROFESSIONALS

Log In

Come Join Us!

Are you an
Engineering professional?
Join Eng-Tips Forums!
  • Talk With Other Members
  • Be Notified Of Responses
    To Your Posts
  • Keyword Search
  • One-Click Access To Your
    Favorite Forums
  • Automated Signatures
    On Your Posts
  • Best Of All, It's Free!
  • Students Click Here

*Eng-Tips's functionality depends on members receiving e-mail. By joining you are opting in to receive e-mail.

Posting Guidelines

Promoting, selling, recruiting, coursework and thesis posting is forbidden.

Students Click Here

Jobs

Viewing data in a graph vary with 'real' time

Viewing data in a graph vary with 'real' time

Viewing data in a graph vary with 'real' time

(OP)
I have two columns of data which, via a command button and a macro to perform some calculations, the values change. When I plot these values I want the viewer to see the graph alter as the data changes. In the spreadsheet I see the data in the columns change but the graph just freezes, until the calculations have finished. So I see the initial graph and the final graph but no nice smooth change as the data varies. I've tried using a sleep function but that just seems to stop the macro from working, and the graph remains frozen until its finished. Any ideas on how to solve this?

RE: Viewing data in a graph vary with 'real' time

Depends on what you macro is doing, but in general I'd think you need to force a sheet recalculation inside your macro.

RE: Viewing data in a graph vary with 'real' time

(OP)
Many thanks. I've inserted ActiveSheet.Calculate within the macro and now it works fine.

RE: Viewing data in a graph vary with 'real' time

I would agree with that assessment. Note also, doing so will probably slow down your macro by an order of magnitude. I don't think Excel can incrementally draw on a graph; it would refresh the entire graph each time.

TTFN
FAQ731-376: Eng-Tips.com Forum Policies

Red Flag This Post

Please let us know here why this post is inappropriate. Reasons such as off-topic, duplicates, flames, illegal, vulgar, or students posting their homework.

Red Flag Submitted

Thank you for helping keep Eng-Tips Forums free from inappropriate posts.
The Eng-Tips staff will check this out and take appropriate action.

Reply To This Thread

Posting in the Eng-Tips forums is a member-only feature.

Click Here to join Eng-Tips and talk with other members!


Resources