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 21-06-2012, 16:24
runflacruiser's Avatar
runflacruiser runflacruiser is offline
Senior Member
 
Join Date: Jun 2009
Location: Pigeon Forge, TN USA
Posts: 811
Default What causes need for this redo?

Hi.
The BreakApartEx sometimes works and sometimes doesn't.
All shapes prior are correct.
I put in a redo and the code works everytime. Also if I am in debug mode I can select the shapes and break apart. It just seems that BreakApartEx fails on occasion.

CorelDraw X5, sample section of code with redo:

Code:
redoBreakApartEx:
            Dim tempCountForRedo&
            tempCountForRedo = 0
            Set boxSr = trimmed.BreakApartEx 'breakapart two halfs and assign to shaperange
            If boxSr.count = 0 Then
                tempCountForRedo = tempCountForRedo + 1
                If tempCountForRedo = 2 Then GoTo ShapeRangeHasShapes:
                GoTo redoBreakApartEx:
            End If
ShapeRangeHasShapes:
~John

Last edited by runflacruiser; 21-06-2012 at 16:28.
Reply With Quote
  #2  
Old 22-06-2012, 17:16
shelbym's Avatar
shelbym shelbym is offline
Senior Member
 
Join Date: Nov 2002
Location: Cheyenne, WY
Posts: 1,788
Blog Entries: 12
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 BreakApart

So if you break apart manual it always works, but trying via code it doesn't. Is that correct? What type of shapes are you working with? Text? Curves?

-Shelby
Reply With Quote
  #3  
Old 24-06-2012, 09:37
runflacruiser's Avatar
runflacruiser runflacruiser is offline
Senior Member
 
Join Date: Jun 2009
Location: Pigeon Forge, TN USA
Posts: 811
Default

IH.
Working with 2 rectangles that are combined. It works fine in debug mode when I slowly go through it. In this instance it is coming from a sub that used do events. I think there is a delay in the program getting back control that may be causing the breakapartex not to work. If I do the redo workaround above it works fine. If I put code in debug mode I can go to Draw and breakapart shapes fine. Just seems breakapartex work all the time consistently.
~John
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

Similar Threads
Thread Thread Starter Forum Replies Last Post
Trapping Undo/Redo squonk CorelDRAW/Corel DESIGNER VBA 0 08-10-2007 23:13


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


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