Private Sub SectionDetails_Format(ByVal pFormattingInfo As Object)
    Dim bmpHold As StdPicture               ' object to hold the bitmap
    Dim iModNum As Integer    ' Calculate an integer to pass in as the bmp name.
    iModNum = cRecNum.Value Mod 3 + 1    Select Case iModNum
    Case 1
        ' Set our variable to an bitmap
        Set bmpHold = LoadPicture(App.Path & "\res\SampleBitmap1.bmp")
        ' Set the height and width of the Report object equal to the actual values for
        ' the bitmap - the StdPicture object defaults to HiMetric, the Report uses twips
        ' Set the bitmap on the Report equal to the variable
        Set cOLEObj.FormattedPicture = bmpHold
        cOLEObj.Height = bmpHold.Height * 567 / 1000   ' convert from HiMetric to Twips
        cOLEObj.Width = bmpHold.Width * 567 / 1000     ' convert from HiMetric to Twips
   End Select
    
End Sub