Closed Thread
Results 1 to 3 of 3

Problem: How to run Excel Solver while viewing a graph?

  1. #1
    Registered User
    Join Date
    12-29-2008
    Location
    Vienna
    MS-Off Ver
    Excel 2003
    Posts
    1

    Problem: How to run Excel Solver while viewing a graph?

    Problem: How to run Solver while viewing a graph?


    Houston I have a Problem!


    The outset:
    I am running a complex solver problem (typically takes a couple of minutes to hours) the results are then fed into the 20 or so cells solver may change.
    These cells compute a graph in the same workbook, but on a different sheet. (The presets of the Solver are fed in by a macro)
    So far everything goes along fine.

    Basically what I want to do is: Display the Graph while Solver is active (to judge the progress he is making)

    I tried many variants all of them failed:

    First approach:

    Sheets("Main Fit Chart").Activate
    SolverSolve


    This results in a runtime Error “1004” Method ‘Range’ of object ‘_Global’ failed. It would not be very helpful anyhow since Excel does not update the cell values while Solver is running..



    My second attempt was to create a loop like this one:

    SolverOptions MaxTime:=10000, Iterations:=2, Precision:=0.0000001
    ‘ Reducing the number of Iterations to 2 and doing this for a 1000 times:
    For x = 1 To 1000
    ScreenUpdating = True
    Sheets("Main Fit Chart").Activate
    ScreenUpdating = False
    Sheets("Fitting").Select
    SolverSolve
    Next x



    But surprisingly Solver seems more powerful than the ScreenUpdating = False command, hence the graph is only displayed for a millisecond than the fitting screen is magically activated and solver does his mystiques…

    Any Ideas?

    Thank you much,

    Axel

  2. #2
    Forum Expert shg's Avatar
    Join Date
    06-20-2007
    Location
    The Great State of Texas
    MS-Off Ver
    2003, 2010
    Posts
    40,678
    Welcome to the forum.

    Please take a few minutes to read the forum rules, then edit your post to add code tags.
    Entia non sunt multiplicanda sine necessitate

  3. #3
    Forum Moderator Leith Ross's Avatar
    Join Date
    01-15-2005
    Location
    San Francisco, Ca
    MS-Off Ver
    2000, 2003, & 2010
    Posts
    23,258
    Hello Axel,

    I am closing this post for 2 reasons. First, you failed to comply with SHG's request and second you have cross-posted this on the Code Cage site...

    How to run Solver while viewing a graph?

    Please contact me by private message when you decide to comply with forum rules, and then I'll reopen it.

    Sincerely,
    Leith Ross

Closed Thread

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Tags for this Thread

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts

Search Engine Friendly URLs by vBSEO 3.6.0 RC 1