Can you have a List Box or Combo Box with Formatting and Colors in Microsoft Access?

Поделиться
HTML-код
  • Опубликовано: 20 окт 2024

Комментарии • 19

  • @SonicVisualGR
    @SonicVisualGR Год назад +1

    I can't believe this simple thing of coloring a listbox item is not implemented in the latest MS Office 365, and one must come out with this kind of mambo jumbo design and coding.
    I can't even believe the VBA editor is completely the same as it was 20-25 years ago when I last time did some simple Access forms in Windows 98 / XP.
    So it looks like Office 365 is an Office 97 with some fancy CSS applied on the UI.
    I wonder what are all developers at Microsoft Office department doing all these years ?!

    • @599CD
      @599CD  Год назад

      [Whistles to himself]

  • @rabidfollower
    @rabidfollower 2 года назад +1

    A list box with rich text is easier to fake because it is always opened. But a fake combo box that can open and collapse, open when F4 is pressed, shut when Esc is pressed, etc. would be considerably more work. The ability to store an invisible column as the bound field is also a tricky thing to fake. A combo box can also auto-complete as you type and go straight to the matching item on the list, which is another thing you have to duplicate. A combo box can also open upward if it is near the bottom of the screen. It can even detect the edge of your monitor screen so it always stays visible. It can even open when it is TOTALLY OFF THE SCREEN (when you press F4)! This is a magical combo box, and it's tough to duplicate. It's possible (I guess) to create a near-exact copy of it, but you would probably find that it is just too much more effort than it is worth.

    • @599CD
      @599CD  2 года назад

      Yeah... that's why I say if you REALLY need those colors, the subform trick works well.

  • @rabidfollower
    @rabidfollower 2 года назад

    Hi Richard, I just posted a reply to someone on your 599cd site forum under General Access Forum, subject "Combo box formatting." The original poster asked a **most interesting** question that I had to dig deep into my memory to find an answer. You may make a video out of it as well. The poster saw different colors in the columns of her combo box and wondered why. I replied that this is in fact an Access feature (a very old one too). In table design, the Format property of each field actually sets the display color of the field whenever and wherever the table's data are displayed: in datasheets, queries, data from SQL constructed in VBA, etc. If a combo box has a rowsource that uses such a table, it will "inherit" the color settings from that table's design. The Format string looks something like: [Blue];@ . Not many colors are available, and the colors look ugly, so this feature is not much use for formatting the look of combo boxes. But this may make a great follow-up video to this video. P.S. When I posted the video on your 599cd site forum, it used my real name that was tied to my payment info. Is it possible to change my display name to rabid follower? It's not a big deal if it isn't.

    • @599CD
      @599CD  2 года назад

      Inspiration for: 599cd.com/ColumnColors

  • @Osiris_fc
    @Osiris_fc 3 года назад +1

    Thanks so much

    • @599CD
      @599CD  3 года назад

      You're welcome!

  • @TruthSeeker-3150
    @TruthSeeker-3150 4 года назад

    Is there any way to format numbers in an access listbox as currency?

    • @599CD
      @599CD  3 года назад

      Sure. If the field is a Currency field, the list box should automatically format it as Currency. If not, you can specify using the Format function in the SQL of the Row Source: Format(MyField,"Currency")

  • @salamvakalur5541
    @salamvakalur5541 4 года назад

    You cant reference a property or method for a controle unless the control has the focus
    Why this error message appear when the form run

    • @599CD
      @599CD  4 года назад +1

      Sure, you can reference properties for control that don't have focus. From anywhere on a form, you could say
      FirstName.Visible = True
      or something like that.

  • @matorwmasen
    @matorwmasen 3 года назад

    Pls, how to apply color to a listbox Column header.

    • @599CD
      @599CD  3 года назад

      Can't be done. Don't use column headers in list boxes. Put labels above each column and color those however you like.

    • @DavenneChua
      @DavenneChua Год назад

      I set columnsheaders to no and just make a textbox above. Then you can change the textbox any color and even center it.

  • @abdulhamidalhaddadi2255
    @abdulhamidalhaddadi2255 Год назад

    👍

  • @imstevemcqueen
    @imstevemcqueen 3 года назад

    Guru

    • @599CD
      @599CD  3 года назад

      Who... me? :)