Hi,
I have a database of songs on MS Access which then produces a PowerPoint presentation of the chosen songs with each verse on a different slide. This all works fine but now I would like to add in an option in the database to tick a check box if the words are part of the song chorus which should then make that slide in italics. I have tried this:
For intVerse = 16 To 1 Step -1
If IsNull(rs.Fields("Song " & intItem & " chosen_Verse " & intVerse).Value) Then
'------
Else
With .Slides.Add(rs.AbsolutePosition + 1, ppLayoutLargeObject)
.FollowMasterBackground = False
.Background.Fill.Solid
.Background.Fill.ForeColor.RGB = RGB(0, 0, 0)
With .NotesPage.Shapes.Placeholders(2)
.TextFrame.TextRange.Text = rs.Fields("Song " & intItem & " chosen.Notes")
End With
With .Shapes(1).TextFrame.TextRange
.Text = CStr(rs.Fields("Song " & intItem & " chosen_Verse " & intVerse).Value)
.Characters.Font.Color.RGB = RGB(255, 255, 255)
.Characters.Font.Size = 30
If (rs.Fields("Song " & intItem & " chosen.Chorus" & intVerse).Value) = True Then '-- THIS STATEMENT NOT WORKING
.Characters.Font.Italic = True
Else
.Characters.Font.Italic = False
End If
.ParagraphFormat.Bullet = False
.ParagraphFormat.Alignment = ppAlignCenter
End With
If IsNull(rs.Fields("Song " & intItem & " chosen_Verse " & intVerse + 1).Value) Then
With .Shapes.AddTextbox(msoTextOrientationHorizontal, Left:=46.5, Top:=474, Width:=627, Height:=51).TextFrame.TextRange
.Text = rs.Fields("Song " & intItem & " chosen.Copyright Info")
.Characters.Font.Color.RGB = RGB(255, 255, 255)
.Font.Size = 14
.ParagraphFormat.Alignment = ppAlignRight
End With
Else
End If
End With
'--------------------------------------------------------------------------------------------------------------------
End If
Next intVerse
Next intItem
But this code seems to be ignoring the IF statement and just putting everything into italics even if the checkbox (Chorus1) is not ticked. Any ideas?