OberonPlace.com Forums

OberonPlace.com Forums (http://forum.oberonplace.com/index.php)
-   CorelDRAW/Corel DESIGNER VBA (http://forum.oberonplace.com/forumdisplay.php?f=16)
-   -   Insert space then delete space (http://forum.oberonplace.com/showthread.php?t=24828)

gorgo 19-03-2019 14:27

Insert space then delete space
I need to insert a space between text, then delete it. Is there a macro for this?

knowbodynow 22-04-2019 19:44

What kind of text? Under what circumstances? The following macro works with x6. For selected artistic text if the character spacing is 0 it makes it 200. if the spacing is not 0 then it makes it 0:


Sub ToggleSpacepace()

Dim s As Shape

If ActiveSelection.Shapes.Count = 0 Then

    MsgBox "Please Select some text to process", vbInformation, "Nothing Selected!"
    Exit Sub

End If

For Each s In ActiveSelection.Shapes

    If s.Type = cdrTextShape Then
        If s.text.Story.CharSpacing = 0 Then
        s.text.Story.CharSpacing = 200
        s.text.Story.CharSpacing = 0
        End If
    End If

Next s

End Sub

All times are GMT -5. The time now is 20:02.

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