Jump to content
Developer Wiki and Function Reference Links ×

Resetobject takes To much time.


Musisback

Recommended Posts

When I reset an PIO from a script, it takes a a pretty long time to redraw (a few second) although,it shouldn't because the PIO is very simple. (it tried with a rect(0,0,100,100) as PIO and the same think happens.)

The weird thing is that when the VW file is new it works quite fast but when I work on the same file for a long time, it becomes very slow.

Does anyone know what causes that and how to solves it?

Thanks

Link to comment

How many UNDO levels have you specified in your VW Preferences? How many objects do you have in your file? If both numbers are large, that might explain the slowdown. Closing the file and restarting the program erase your history and speed things up. This is not the only cause of a slowdown, but it's a predictable one.

To test, set your undo count to 0 or 1, close the Preferences dialogue, then reset your count. If things speed up, that's probably it. If you can live with a lower number, try it. I use 20 and rarely, if ever, see unexplained slowdowns. Your mileage may vary.

Raymond

Link to comment

If you also draw construction geometry that gets deleted at some time in the script, it will be added to the history. You can block this type of code out of the history with the BeginContext and EndContext procedures.

You might also want to test how many times the PIO gets reset with the script by using the {$DEBUG} directive in the PIO script. If your code has a reset within the PIO script and an exception is not handled correctly, it could go into loop.

Link to comment

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Reply to this topic...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...