buzz44 Posted May 11, 2005 Share Posted May 11, 2005 The optional parametre, $i_colorref, in the ChooseColor() function is passed as BGR when it should be RGB, correct? See below#include <Misc.au3> $color = _ChooseColor (2, 0xFF0000); << Red If (@error) Then MsgBox(0, "", "Error _ChooseColor: " & @error) Else MsgBox(0,"_ChooseColor","Hex RGB Color: " & $color) EndIf qq Link to comment Share on other sites More sharing options...
GaryFrost Posted May 11, 2005 Share Posted May 11, 2005 (edited) that's a hex number not a colorref, red would be 255, example of yellow would be 65535 Edit: one way to get your colorref from a rgb hex is to reverse the r and b in the hex 0xFF0000 becomes 0x0000FF then turn it into a ref by Int(0x0000FF) which will give you 255. Edited May 11, 2005 by gafrost SciTE for AutoItDirections for Submitting Standard UDFs Don't argue with an idiot; people watching may not be able to tell the difference. Link to comment Share on other sites More sharing options...
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now