OberonPlace.com Forums  

Go Back   OberonPlace.com Forums > Developer Forums > VBA > CorelDRAW/Corel DESIGNER VBA

Reply
 
Thread Tools Search this Thread Display Modes
  #1  
Old 03-06-2005, 11:15
DChinell
Guest
 
Posts: n/a
Default Stop and start screen updating?

Hello. I'm new to the forum, and relatively new to VBA.

I've read about optimizing and disabling events etc., to speed up execution. But is there no way to stop and start screen updating, analogous to the Application.ScreenUpdating method?

Thanks for any help you can offer...

Bear
Reply With Quote
  #2  
Old 03-06-2005, 11:26
Alex's Avatar
Alex Alex is offline
Administrator
 
Join Date: Nov 2002
Posts: 1,940
Blog Entries: 4
Default

Setting Application.Optimization to True will stop screen updates:

Code:
Application.Optimization = True
' ...
' ... Do your stuff ...
' ...
Application.Optimization = False
ActiveWindow.Refresh
Application.Refresh
Reply With Quote
  #3  
Old 03-06-2005, 12:05
shelbym's Avatar
shelbym shelbym is offline
Senior Member
 
Join Date: Nov 2002
Location: Cheyenne, WY
Posts: 1,782
Blog Entries: 11
Send a message via ICQ to shelbym Send a message via AIM to shelbym Send a message via MSN to shelbym Send a message via Yahoo to shelbym
Default Too Fast

Alex you are getting to Fast, I can't even get in and answer the easy ones. LOL Good to see you on top of it.

Shelby
Reply With Quote
  #4  
Old 03-06-2005, 12:50
DChinell
Guest
 
Posts: n/a
Default

Thanks! But that raises another question. I'm using CorelDraw 10. Refresh doesn't seem to be a method of Application. Am I missing something?

Bear
Reply With Quote
  #5  
Old 03-06-2005, 14:56
Alex's Avatar
Alex Alex is offline
Administrator
 
Join Date: Nov 2002
Posts: 1,940
Blog Entries: 4
Default

Yes, you are right. Application.Refresh is a new method (I believe it's added in Draw 11, or was it 12?). Anyway, ActiveWindow.Refresh will still update the document window. It's some dockers (like Object Manager) will not be updated properly. But you can always close/reopen the docker manually to get it updated correctly.

But overall, I would strongly suggest you upgrading to at least v11 (or better yet, v12). They are miles away from v10 as far as VBA support is concerned... I guess you can have v11 pretty cheap these days..
Reply With Quote
  #6  
Old 16-11-2008, 14:39
CSewell
Guest
 
Posts: n/a
Default Object Manager docker

I'm having problems with the Object Manager docker (X3) not updating and not responding after running a macro. I tried manually open/closing the docker, but after a few mouse clicks, it stops updating.

I use Application.Refresh and ActiveDocument.Windows.Refresh before exiting the macro and that doesn't help. Is there something else that needs to be done or is this a known problem? I don't have the same problem with other macros, but I can't identify what might be different.

EDIT: Resolved the problem. I had forgotten an "ActiveDocument.EndCommandGroup". The clue was when the UNDO button would not work after running the macro.

Last edited by CSewell; 02-12-2008 at 12:15.
Reply With Quote
Reply


Currently Active Users Viewing This Thread: 1 (0 members and 1 guests)
 
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT -5. The time now is 23:59.


Powered by vBulletin® Version 3.8.1
Copyright ©2000 - 2021, Jelsoft Enterprises Ltd.
Copyright © 2011, Oberonplace.com