Software Developer's Kit - ChemDraw

Send comments on this topic
Justification Property
See Also 

Description

Member of ChemDraw Control.Caption.

Sets and returns the justification for this caption.

Property type

Read-write property

Syntax

Visual Basic
Public Property Justification() As CDJustification

Return Type

Remarks

Sets and returns the justification for the caption (flush left, centered, flush right or justified). Another way to set the justification is using Settings.CaptionJustification.

Example

'Declares a variable Caption
 Dim myCaption As ChemDrawControl10Ctl.Caption

'This example shows how to justify the caption 
 Private Sub cmdCommand_Click()
     Set myCaption = ctlChemDraw.Captions.Item(1)
     Text1.text = myCaption.Justification 
     myCaption.Justification = kCDJustificationCenter  
     'another way to set the justification is:  
     myCaption.Settings.CaptionJustification = kCDJustificationJustified
 End Sub

See Also