ASP.NET Color Picker - AutoPostBack

Current color (click to the box):
Color Picker
Previous color:

This example demonstrates AutoPostBack and PickButton properties use with ColorPostBack event (MS ASP.NET AJAX).

Example code

<script runat="server" language="c#">
private void Color_CallBack(object sender, ColorPostBackEventArgs e){
  color.Style["background-color"] = e.Color;
  previous.Style["background-color"] = e.PreviousColor;
}
</script>
...
<obout:ColorPicker runat="server" ID="picker" TargetId="color" TargetProperty="style.backgroundColor"
                             OnColorPostBack="Color_CallBack" PickButton="false" AutoPostBack="true" >
      <asp:TextBox readOnly="true" id="color" style="cursor: pointer;" runat="server"/>
</obout:ColorPicker>
Previous color:
<asp:TextBox readOnly="true" id="previous" style="width: 40px;" runat="server"/>

Download working example Download.