Results 1 to 7 of 7
  1. #1
    FL_Boy is offline Novice
    Windows 7 64bit Access 2007
    Join Date
    Dec 2011
    Posts
    6

    Alt Codes

    Is there anyway to display these or similar extended Alt Codes using a native CHR or similar function?
    Ideally I'd like to have a Combobox and have the user select one of about 10 of these icons in lieu of a text selection.

    Here's a link to the symbols.



    https://altcodeunicode.com/alt-codes...sport-symbols/


  2. #2
    Micron is offline Virtually Inert Person
    Windows 10 Access 2016
    Join Date
    Jun 2014
    Location
    Ontario, Canada
    Posts
    12,799
    CHRW(####) ?

    e.g. CHRW(9788) will put a sun into a table text field. 9788 is the long integer version of the hexadecimal value if I'm not mistaken.
    I don't know if a combo, textbox or any other control will support unicode - never tried.
    Last edited by Micron; 10-07-2021 at 08:13 PM. Reason: added comment
    The more we hear silence, the more we begin to think about our value in this universe.
    Paraphrase of Professor Brian Cox.

  3. #3
    moke123's Avatar
    moke123 is offline Me.Dirty=True
    Windows 7 32bit Access 2010 32bit
    Join Date
    Oct 2012
    Location
    Ma.
    Posts
    1,654
    I just entered Alt code in a table text field and it does display in both the table and a combobox.
    How it works from there you'll have to experiment.
    If this helped, please click the star * at the bottom left and add to my reputation- Thanks

  4. #4
    davegri's Avatar
    davegri is online now Excess Access
    Windows 10 Access 2016
    Join Date
    May 2012
    Location
    Denver
    Posts
    3,411
    My experiments:

    Click image for larger version. 

Name:	symdesign.png 
Views:	19 
Size:	7.4 KB 
ID:	46371 Click image for larger version. 

Name:	symform.png 
Views:	19 
Size:	6.3 KB 
ID:	46372


    Loaded the images in the textboxes to the value list of the combobox.
    You could make the textboxes not visible.
    Not sure how you would deal with the combobox after_update event to actually use the setup.

    Code:
    Option Compare Database
    Option Explicit
    
    
    Private Sub Form_Load()
        Me.cboList.AddItem Chr$(34) & Me.t1 & Chr$(34) & ";"
        Me.cboList.AddItem Chr$(34) & Me.t2 & Chr$(34) & ";"
        Me.cboList.AddItem Chr$(34) & Me.t3 & Chr$(34) & ";"
        Me.cboList.AddItem Chr$(34) & Me.t4 & Chr$(34) & ";"
        Me.cboList.AddItem Chr$(34) & Me.t5 & Chr$(34) & ";"
        Me.cboList.AddItem Chr$(34) & Me.t6 & Chr$(34) & ";"
    End Sub

  5. #5
    Micron is offline Virtually Inert Person
    Windows 10 Access 2016
    Join Date
    Jun 2014
    Location
    Ontario, Canada
    Posts
    12,799
    Ja, but as you well know, we shouldn't be editing directly in tables
    Besides, I found that when you do that, some characters look like symbols shown at the link while some look like Cyrillic characters but if you use ChrW they are stored as shown at the link. I suspect that's because some Unicode values will be stored as they should be, while others need to be stored as hex values. Not sure if that's because the function converts Alt+values to hex and all hex is properly represented, or if it's something else.

    EDIT -I think if you use the function you can still bind controls rather than using calculated ones that cannot be bound. In my limited testing a form shows the proper unicode characters as long as I use ChrW in an update query.
    The more we hear silence, the more we begin to think about our value in this universe.
    Paraphrase of Professor Brian Cox.

  6. #6
    moke123's Avatar
    moke123 is offline Me.Dirty=True
    Windows 7 32bit Access 2010 32bit
    Join Date
    Oct 2012
    Location
    Ma.
    Posts
    1,654
    I tried a message box and some of the symbols didn't display correctly
    If this helped, please click the star * at the bottom left and add to my reputation- Thanks

  7. #7
    Micron is offline Virtually Inert Person
    Windows 10 Access 2016
    Join Date
    Jun 2014
    Location
    Ontario, Canada
    Posts
    12,799
    I doubt you can show glyphs in a textbox because it only accepts string. That's my 2¢ anyway.

    That's alt+155 BTW.
    The more we hear silence, the more we begin to think about our value in this universe.
    Paraphrase of Professor Brian Cox.

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

Similar Threads

  1. Replies: 4
    Last Post: 11-24-2019, 08:24 AM
  2. Zip codes
    By joecamel9166 in forum Access
    Replies: 4
    Last Post: 04-01-2016, 02:12 PM
  3. Sql codes
    By hawke in forum Programming
    Replies: 1
    Last Post: 01-14-2015, 11:53 AM
  4. Queries and codes
    By alliandrina in forum Queries
    Replies: 2
    Last Post: 05-03-2012, 05:53 PM
  5. Zip Codes
    By Laurie B. in forum Access
    Replies: 6
    Last Post: 02-25-2011, 02:38 PM

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