Microsoft Office Forums

Go Back   Microsoft Office Forums > >

Reply
 
Thread Tools Display Modes
  #1  
Old 03-07-2024, 01:46 AM
MC147 MC147 is offline ToolTip background colour in Excel code Windows 10 ToolTip background colour in Excel code Office 2021
Advanced Beginner
ToolTip background colour in Excel code
 
Join Date: Feb 2022
Posts: 34
MC147 is on a distinguished road
Default ToolTip background colour in Excel code

When I look up the background colour for ToolTips it is


RGB (255, 255, 200) or 13172735 or &H00C8FFFF&

However, in an excel form that has the colour set to the tool tip colour, the value set in the designer for the background colour is &H80000018&

Can anyone explain this discrepancy. I assume it is something to do with one being &H0... and the other &H8...

p.s The reason I wanted to do this, was I wanted to set an Access Form control colour to the ToolTip colour, but when I just copied &H80000018& to the Access field, the colour was basically Black.
Reply With Quote
  #2  
Old 03-07-2024, 06:40 AM
NoSparks NoSparks is offline ToolTip background colour in Excel code Windows 10 ToolTip background colour in Excel code Office 2010
Excel Hobbyist
 
Join Date: Nov 2013
Location: British Columbia, Canada
Posts: 831
NoSparks is just really niceNoSparks is just really niceNoSparks is just really niceNoSparks is just really niceNoSparks is just really nice
Default

I found this when searching for what color is &H80000018&

The &H indicates that it's a hex code. Hexadecimal digits range from 0 to 9 and then A-F (for 10 to 15)
The next 2 digits specify "Red" between 00 and FF which is 0 and 255. (128 in the case of the code mentioned above)
The following 2 digits are "Green" between 00 and FF which is 0 to 255 (0 in this case)
The following 2 digits are "Blue" between 00 and FF which is 0 to 255 (0 in this case)
The last 2 digits before the closing & indicate the transparency or "opacity" from 0 to 255 (24 in this case)

According to that, &H00C8FFFF& is RGB 0,200,255 at transparency of 255

This site is old but may be of some interest to you.
Reply With Quote
  #3  
Old 03-07-2024, 07:51 AM
MC147 MC147 is offline ToolTip background colour in Excel code Windows 10 ToolTip background colour in Excel code Office 2021
Advanced Beginner
ToolTip background colour in Excel code
 
Join Date: Feb 2022
Posts: 34
MC147 is on a distinguished road
Default

Thanks NoSparks, but I am not sure that is correct.
C8 in HEX is 200 and FF in Hex is 255,
So it is the C8FFFF (i.e. the last 6 digits before the final &) that represents the colour of RGB (255, 255, 200) - the order is reversed for the 3 colours.
Its the first digits &H00 that are puzzling and why the same colour in Excel has a code of &H80000018&

Your link was useful though as it says that Excel only recognizes names for Color 1 through 8 (Black, White, Red, Green, Blue, Yellow, Magenta, and Cyan).

This probably explains it as Excel is clearly using a completely different system for storing the colour codes as is used by Access.
Reply With Quote
  #4  
Old 03-07-2024, 10:07 AM
NoSparks NoSparks is offline ToolTip background colour in Excel code Windows 10 ToolTip background colour in Excel code Office 2010
Excel Hobbyist
 
Join Date: Nov 2013
Location: British Columbia, Canada
Posts: 831
NoSparks is just really niceNoSparks is just really niceNoSparks is just really niceNoSparks is just really niceNoSparks is just really nice
Default

You would think a color in MS Office would be a color in MS Office but apparrently not.

Further searching on this came across a converter for Access OLE Colour, RGB & HEX values in a post at ACCESSWORLD Forum from 2018,
and again at DEVelopers HUT that sounds like an update of the same converter.

I don't use Access so not testing them out, and I've never heard of OLE color.
If nothing else might give some more insight into what's going on.
Reply With Quote
  #5  
Old 03-07-2024, 10:36 AM
MC147 MC147 is offline ToolTip background colour in Excel code Windows 10 ToolTip background colour in Excel code Office 2021
Advanced Beginner
ToolTip background colour in Excel code
 
Join Date: Feb 2022
Posts: 34
MC147 is on a distinguished road
Default

Thanks again for the reply.
I shan't pursue this any further, now that I know that I can't just copy across colour codes from Excel to Access. I've got the colour I want now.
I think Excel uses a much smaller colour palette and probably the &H8 at the start indicates that it is only using the 8 colours mentioned below. It may even be using a smaller integer to store the codes than Access does.
Maybe in 64 bit Excel it is different.
Reply With Quote
Reply



Similar Threads
Thread Thread Starter Forum Replies Last Post
ToolTip background colour in Excel code How to change background 'paper' colour? wiganken Office 2 11-29-2020 04:34 AM
ToolTip background colour in Excel code Changing background colour in table based on value. amandalee Word Tables 21 09-30-2020 03:13 PM
Background Word Colour not showing on PDF phorsley Word 1 04-24-2020 09:18 AM
ToolTip background colour in Excel code Text Background Colour in a Table Colin Vicary Word 4 08-08-2019 06:02 AM
Trying to clear the background colour from a theme ezekiel181 Word 1 11-14-2010 07:29 AM

Other Forums: Access Forums

All times are GMT -7. The time now is 02:47 PM.


Powered by vBulletin® Version 3.8.11
Copyright ©2000 - 2024, vBulletin Solutions Inc.
Search Engine Optimisation provided by DragonByte SEO (Lite) - vBulletin Mods & Addons Copyright © 2024 DragonByte Technologies Ltd.
MSOfficeForums.com is not affiliated with Microsoft