View Single Post
 
Old 06-15-2016, 04:39 PM
PSSMargaret PSSMargaret is offline Windows 10 Office 2010 64bit
Novice
 
Join Date: May 2016
Posts: 28
PSSMargaret is on a distinguished road
Default

gmaxey,

The below code you provided has worked perfectly with all of my testinig. The form I'm developing contains rich text content controls. You have to enter a shift+enter for a carriage return for a new paragraph. Is there any code that we can add to this, or separate code, that will assure the first letter of a new paragraph after two shift+enters will automatically be capitalized?

Margaret

Code:
Private Sub Document_ContentControlOnExit(ByVal CCtrl As ContentControl, Cancel As Boolean)
With CCtrl
  Select Case .Type
    Case wdContentControlText, wdContentControlRichText, wdContentControlComboBox
      On Error Resume Next
      .Range.Characters.First = UCase(.Range.Characters.First)
      Case Else
  End Select
End With
End Sub
Reply With Quote