Random color with certain range noob style :)

I am trying to exclude dark(er) colors, not sure this is the right way, but its the best with my level of knowledge :smiley:

var color:uint = (Math.floor(Math.random() * 0xFFFFFF));
function randomColor(color:uint):uint {
    if ((color).toString(16) < 0x333333) {//I am getting an error if I try this
        return color;
    }
}
randomColor(color);
trace((color).toString(16));

ofcourse, I appreciate any advice concering better coding of random color :stuck_out_tongue: