VB.net Excel Add-in ARGB color vs RGB Color in Excel

Hi.
I was told by an Expert how to get the RGB color of an Excel cell using the following VBA code
What is the difference between the ARGB color in VB.net and the RGB color in Excel VBA?

Sub oGet()
Dim lColor As Long
lColor = Selection.Interior.Color

MsgBox "Red: " & lColor Mod 256 & vbCrLf & _
            "Green: " & Int(lColor / 256) Mod 256 & vbCrLf & _
            "Blue:" & Int(lColor / 256 ^ 2) Mod 256
End Sub
Murray BrownMicrosoft Cloud Azure/Excel Solution DeveloperAsked:
Who is Participating?

Improve company productivity with a Business Account.Sign Up

x
 
nutschConnect With a Mentor Commented:
The A is for Alpha, i.e. the transparency factor, from 0 opaque to 255 transparent.
0
 
Murray BrownMicrosoft Cloud Azure/Excel Solution DeveloperAuthor Commented:
Thanks
0
Question has a verified solution.

Are you are experiencing a similar issue? Get a personalized answer when you ask a related question.

Have a better answer? Share it in a comment.

All Courses

From novice to tech pro — start learning today.