Results 1 to 5 of 5
  1. #1
    Middlemarch is offline Competent Performer
    Windows 10 Access 2019
    Join Date
    Mar 2015
    Posts
    479

    Rich Text


    I have an unbound text box where I've changed text format to Rich text.
    It still displays 'normal' text, but if I wanted different colors or italics how might I achieve this? Are there any examples?

    Second problem. Google keeps telling me to change the Long text format in the table field? But there's no table for an unbound control and can't find
    if a bound table is the only way to have rich text - or if assigning a colour-aware or formatted string directly to the rich text box will work.

  2. #2
    Middlemarch is offline Competent Performer
    Windows 10 Access 2019
    Join Date
    Mar 2015
    Posts
    479
    Ok I have got somehere. Lloks like I may not need a bound control.

    Me.txtEC = "<i>My pet dragon is called Burt.</i>" & vbCrLf & "<b>My pet dragon is called Burt.</b>"

    This does bold an Italic but the VBCRLF fails - and I don't (yet) know how to set a color.
    Any help appreciated.

  3. #3
    Minty is offline VIP
    Windows 10 Office 365
    Join Date
    Sep 2017
    Location
    UK - Wiltshire
    Posts
    3,157
    The VbCrLf would be a <div>My text goes here</div>
    or possibly a <p> for paragraph, or <b> for line break.

    Colours:
    <font color="#0072BC">single </font>phase
    DLookup Syntax and others http://access.mvps.org/access/general/gen0018.htm
    Please use the star below the post to say thanks if we have helped !
    ↓↓ It's down here ↓↓

  4. #4
    Middlemarch is offline Competent Performer
    Windows 10 Access 2019
    Join Date
    Mar 2015
    Posts
    479
    Thanks Minty, I'm working with these <> </> chars for the first time.

  5. #5
    Minty is offline VIP
    Windows 10 Office 365
    Join Date
    Sep 2017
    Location
    UK - Wiltshire
    Posts
    3,157
    Make a simple form with the field on it formatted to Rich Text, and then right click and format to your hearts content.
    Then look at the results directly in the table, you will see all the formatting codes.
    DLookup Syntax and others http://access.mvps.org/access/general/gen0018.htm
    Please use the star below the post to say thanks if we have helped !
    ↓↓ It's down here ↓↓

Please reply to this thread with any new information or opinions.

Similar Threads

  1. Setting Font size in text box, set to rich text
    By Miles R in forum Programming
    Replies: 5
    Last Post: 09-01-2021, 11:55 AM
  2. Replies: 8
    Last Post: 06-18-2021, 04:22 PM
  3. Rich text field not displaying rich text properly
    By CodeLiftSleep in forum Access
    Replies: 4
    Last Post: 01-24-2018, 10:59 AM
  4. Replies: 3
    Last Post: 06-04-2017, 01:02 PM
  5. Replies: 4
    Last Post: 08-07-2015, 07:49 AM

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
Other Forums: Microsoft Office Forums