excel - Autoupdating userform for each loop without needing to response to the userform -


i know if possible autoupdate userform in vba?

in case:

    while cells(57, 3) > (cells(47, 3) - cells(46, 3) + 0)      cells(52, 3) = cells(52, 3) + 0.5      call foto_2      wend 

as can see in code above, have loop change value of cell.

and value of cell link graphique

by calling foto_2, updating image on userform.

here code in userform contain image of foto_2,

private sub userform_initialize() call foto_2 end sub 

while code foto_2,

sub foto_2()      application.screenupdating = false      fname = ....         sheets(1).chartobjects("foto_2").chart.export filename:=fname, filtername:="gif"      userform1.image1.picture = loadpicture(fname)  end sub 

in foto_2 procedure, place doevents after last line:

sub foto_2()  application.screenupdating = false  fname = ....     sheets(1).chartobjects("foto_2").chart.export filename:=fname, filtername:="gif"  userform1.image1.picture = loadpicture(fname) doevents  end sub 

Comments

Popular posts from this blog

java - UnknownEntityTypeException: Unable to locate persister (Hibernate 5.0) -

python - ValueError: empty vocabulary; perhaps the documents only contain stop words -

ubuntu - collect2: fatal error: ld terminated with signal 9 [Killed] -