Your Privacy Matters: We use our own and third-party cookies to improve your experience on our website. By continuing to use the website we understand that you accept their use. Cookie Policy
535
Tri State Editor?
posted

I have a database that uses a tri-state column (integer) that currently uses 0=unknown, 1=yes, -1=no although those codes could change easily.  In PHP I wrote a simple drop down that uses images a checkmark for yes, a X for no and blank for unknown.  I'd like to use a similar type setup with ultragrid.  is this possible? If so I could use some pointers in the right direction as I am just now experimenting with ultragrid.

Peter

Parents
  • 37774
    posted

     You could do this using an UltraCheckEditor as the EditorControl of a grid column; in the 8.2 release, I *think*, there was a new GlyphInfo property that was added to the check editor that allows you to specify custom images for each of the states.  You would still likely need to use a DataFilter to convert your values to a nullable boolean type, though, since 0 would be parsed as 'false' and I don't know how it would treat '-1'.  There is already an example of a DataFilter for checkboxes in the KB that should help you out in this regard.

    -Matt

Reply Children