Results 1 to 3 of 3
  1. #1
    New Lounger
    Join Date
    Oct 2003
    Location
    Long Beach, California, USA
    Posts
    7
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Bolding a detail line using code (Access 2002 SP3)

    I have a report that run a query under certain condition (using code). I don't know how to bold the font (again, using code) on the detail line fields that meet that condition. Please help. Thank you. Ryan

  2. #2
    Plutonium Lounger
    Join Date
    Mar 2002
    Posts
    84,353
    Thanks
    0
    Thanked 29 Times in 29 Posts

    Re: Bolding a detail line using code (Access 2002 SP3)

    You can handle this in the On Format event of the detail section of the report:

    Private Sub Details_Format(Cancel As Integer, FormatCount As Integer)
    Me.txtField1.FontBold = condition
    End Sub

    where txtField1 is the name of a text box in the detail section, and condition is an expression that evaluates to True or False. If you need to set format more than one control, just add similar lines to the event procedure.

  3. #3
    New Lounger
    Join Date
    Oct 2003
    Location
    Long Beach, California, USA
    Posts
    7
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Re: Bolding a detail line using code (Access 2002 SP3)

    Thank you HansV. I tried it and it works fine. Ryan

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •