OberonPlace.com Forums

OberonPlace.com Forums (http://forum.oberonplace.com/index.php)
-   Macros/Add-ons (http://forum.oberonplace.com/forumdisplay.php?f=21)
-   -   Document Colors (http://forum.oberonplace.com/showthread.php?t=24810)

mtracy 01-06-2018 09:48

1 Attachment(s)
works but

Attachment 1240

mtracy 01-06-2018 09:49

And still has black even though nothing black exists in the doc

mtracy 01-06-2018 10:03

1 Attachment(s)
doc palette explained

Attachment 1241

shark 04-06-2018 02:52

works but
 
what version of Corel Draw do you have?

mtracy 04-06-2018 09:42

Gettin' there. Still kind of "buggy"

Seems you had to select all shapes first so I added a line after
...Set srAllShapes = ActivePage.Shapes.All
srAllShapes.AddToSelection

Would also need a
If new color found that's not already in the palette then add to palette
So if you did an undo the palette could be upadated

Error when palette is already correct and you run the macro to update. Deletes colors from the palette when it shouldn't do anything.

mtracy 08-06-2018 16:00

Nope. This one is close but doesn't work if Pantone colors are used.

Sub Reset_DocPalette()

ResetPalette ActiveDocument
End Sub

Sub ResetPalette(ByRef iDoc As Document)

Dim CurColNo As Integer, CurPg As Page, CurSh As Shape, CurSR As ShapeRange, DoIt As Boolean

For CurColNo = iDoc.Palette.Colors.Count To 1 Step -1
DoIt = True
For Each CurPg In iDoc.Pages
Set CurSR = CurPg.Shapes.All
If CurSR.Shapes.Count > 0 Then
For Each CurSh In CurSR.Shapes
'If CurSh.Fill.Type = cdrUniformFill Then CurSh.Fill.UniformColor.ConvertToCMYK
If CurSh.Fill.Type = cdrUniformFill Then

If CurSh.Fill.UniformColor.IsSame(iDoc.Palette.Colors(CurColNo)) Then DoIt = False
End If


All times are GMT -5. The time now is 05:26.

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