CheckBoxColumn with Cross Mark

3 posts, 0 answers
  1. Bradley Lane
    Bradley Lane avatar
    22 posts
    Member since:
    Aug 2012

    Posted 21 Feb 2012 Link to this post

    Hi,

    I want to change a GridViewCheckBoxColumn to display a red Cross Mark instead of the green Tick Mark.

    Is this possible and if so how?

    Kind Regards,
    Brad
  2. Princy
    Princy avatar
    17421 posts
    Member since:
    Mar 2007

    Posted 22 Feb 2012 Link to this post

    Hello,

    Check the following forum thread which discussed similar scenario.
    GridViewCheckBoxColumn changed CheckBox image

    Thanks,
    Princy.
  3. Boryana
    Admin
    Boryana avatar
    330 posts

    Posted 24 Feb 2012 Link to this post

    Hello everyone,

    Thank you for writing.

    Princy has pointed a related forum thread that contains one possible implementation of the requirement. Simply handle the CellFormatting event, set the CheckPrimitiveStyle to None and the DrawFill to False, and assign images to each state accordingly.

    Another way of getting the same behavior is through using a custom theme. Here are the list of steps you need to make:
    1. Start the Visual Style Builder tool (Starting VSB). You might also want to get acquainted with its basic concepts (Getting Started).
    2. Export the built-in themes and load the tssp you would like to customize (Loading Predefined Themes)
    3. In the Control Panel (appearing on the left) expand RadCheckMark and select the nested RadCheckMark item.
    4. In the Elements panel select and expand the CheckPrimitive item. Navigate to the CheckPrimitiveStyle and set it to None. In the Element states panel select the ToggleState=on state and again set the CheckPrimitiveStyle to None.
    5. In the Elements panel select and expand  the ImagePrimitive item. Assign the appropriate images to the Image property for both RadCheckMark and RadCheckMark.ToggleState=on states.
    6. Save the tssp file (Saving and Loading Themes)
    7. Load the theme in your application (Load Themes from an External File, Load Themes from a Resource)

    I hope you find this useful. Do not hesitate to write back if you have further queries.

    Regards,
    Boryana
    the Telerik team
    RadControls for WinForms Q1'12 release is now live! Check out what's new or download a free trial >>
Back to Top