Skip to main content
Participant
January 5, 2007
Question

no property name

  • January 5, 2007
  • 1 reply
  • 171 views
I found this beautiful color wheel app..
http://www.peterjoel.com/Samples/index.php?go=cmyk

When I publish it in AS 2.0 I get this error:
There is no property with the name 'RGB_to_HSB'.

Color.RGB_to_HSB = function(colRGB) {
}

Can this logic be easily updated to AS 2? If not, can someone point me in the right direction? I have searched the forums and read the AS Migration documents and couldn't find anything in my language.
This topic has been closed for replies.

1 reply

Inspiring
January 6, 2007
> Color.RGB_to_HSB = function(colRGB) {
> }

For a start .. thats a bit odd assigning an empty function to it (maybe you
just removed the guts of the function for clarity)

To do what you want try:

Color["RGB_to_HSB"] = function(colRGB) {
}

or, if that fails

var RGB_to_HSB_name = "RGB_to_HSB";
Color["RGB_to_HSB_name"] = function(colRGB) {
}
--
Jeckyl