dionel1969 Posted August 22, 2011 Posted August 22, 2011 Hello Farshad!!! I just want to know if will be possible soon to draw images on grids (StringGrid or DBGrid) ??? Or DataView from ExtJS will be implemented??? I need to draw an image of state of POS (1-Inactive, 2-Active, Turned Off, 3-Active Turned On w/o Sale and 4- Active, Turned On w/ Sale) on a surface. This surface could be a Grid of DataView like an example of ExtJS (.../uniGUI/ext-3.3.0/examples/view/animated-dataview.html). I don't need the animation but it could be. Best regards, Quote
JasonReid Posted August 23, 2011 Posted August 23, 2011 Hello Farshad!!! I just want to know if will be possible soon to draw images on grids (StringGrid or DBGrid) ??? Or DataView from ExtJS will be implemented??? I need to draw an image of state of POS (1-Inactive, 2-Active, Turned Off, 3-Active Turned On w/o Sale and 4- Active, Turned On w/ Sale) on a surface. This surface could be a Grid of DataView like an example of ExtJS (.../uniGUI/ext-3.3.0/examples/view/animated-dataview.html). I don't need the animation but it could be. Best regards, i add state images to my grid using calculated fields. Like so : aStatus := Uppercase(ISSUES_TISSUE_STATUS.Value); If aStatus = 'CLOSED' then ISSUES_TImageIcon.Value := '<img width=16 height=16 src="http://URL.com/images/tick.bmp"/>' Else if aStatus = 'RESEARCHING' then ISSUES_TImageIcon.Value := '<img width=16 height=16 src="http://URL.com/images/research.bmp"/>' Else if aStatus = 'REPORTED' then ISSUES_TImageIcon.Value := '<img width=16 height=16 src="http://URL.com/images/reported.bmp"/>' Else if aStatus = 'CAN CLOSE' then ISSUES_TImageIcon.Value := '<img width=16 height=16 src="http://reidspace.com/images/flag_green.bmp"/>' Else ISSUES_TImageIcon.Value := '<img width=16 height=16 src="http://URL.com/images/open.bmp"/>' ; Quote
dionel1969 Posted August 23, 2011 Author Posted August 23, 2011 i add state images to my grid using calculated fields. Like so : aStatus := Uppercase(ISSUES_TISSUE_STATUS.Value); If aStatus = 'CLOSED' then ISSUES_TImageIcon.Value := '<img width=16 height=16 src="http://URL.com/images/tick.bmp"/>' Else if aStatus = 'RESEARCHING' then ISSUES_TImageIcon.Value := '<img width=16 height=16 src="http://URL.com/images/research.bmp"/>' Else if aStatus = 'REPORTED' then ISSUES_TImageIcon.Value := '<img width=16 height=16 src="http://URL.com/images/reported.bmp"/>' Else if aStatus = 'CAN CLOSE' then ISSUES_TImageIcon.Value := '<img width=16 height=16 src="http://reidspace.com/images/flag_green.bmp"/>' Else ISSUES_TImageIcon.Value := '<img width=16 height=16 src="http://URL.com/images/open.bmp"/>' ; Thank you. More or less what I need. One more question: images could be .png or .jpg??? I will test it any way now. Thank you so much. Quote
dionel1969 Posted August 23, 2011 Author Posted August 23, 2011 Yes it works as I expected. Thank you again. I can use it. In future will be better to use ListView, but in the future. Quote
lucksjb Posted March 5, 2013 Posted March 5, 2013 How can I adjust size of column with this image ? tnx advanced Luciano Quote
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.