NSColor RGB to Adobe Illustrator RGB

I ran into this problem today:

I am getting a color from a color well and using that value to build a new swatch in adobe illustrator.


set theColor to theColorWell
set rColor to theColor's redComponent() * 100
set gColor to theColor's greenComponent() * 100
set bColor to theColor's blueComponent() * 100
tell application "Adobe Illustrator"
	make new swatch in current document with properties {name:"newColor", color:{red:(rColor), green:(gColor), blue:(bColor)}}
	set theSwatchGroup to swatchgroup "newSwatches" of current document
        set newColorSwatch to swatch "newColor" of current document
        add swatch theSwatchGroup swatch newColorSwatch
end tell

It works… however the colors vary from what the color well displays and what illustrator displays… significantly.
What am I missing?

Figured it out! I miss calculated the rgb values and it totally slipped my mind!

should be

set theColor to theColorWell
set rColor to theColor's redComponent() * 265
set gColor to theColor's greenComponent() * 265
set bColor to theColor's blueComponent() * 265
tell application "Adobe Illustrator"
   make new swatch in current document with properties {name:"newColor", color:{red:(rColor), green:(gColor), blue:(bColor)}}
   set theSwatchGroup to swatchgroup "newSwatches" of current document
set newColorSwatch to swatch "newColor" of current document
add swatch theSwatchGroup swatch newColorSwatch
end tell