Grid change color scheme not working

Hello,
I have a DEM with TIFF format and a color scheme. I’m trying to change the color scheme to other color scheme but after it`s not work. I note that property ImageColorScheme of Image is not changed after I set the new value.
Here is my code in pascal, where IMG is created from a DEM file:

  img.TransparencyColor := 0;
  IMG.ImageColorScheme := FallLeaves;   <--- this line not work is read only?
  img.UseTransparencyColor := true;
  Map.Redraw;

I observed the IMG.ImageColorScheme := FallLeaves not change. Does someone could help me please or give a idea how do it in C?

Thanks