dionel1969 Posted August 22, 2011 Share 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 Link to comment Share on other sites More sharing options...
JasonReid Posted August 23, 2011 Share 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 Link to comment Share on other sites More sharing options...
dionel1969 Posted August 23, 2011 Author Share 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 Link to comment Share on other sites More sharing options...
dionel1969 Posted August 23, 2011 Author Share 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 Link to comment Share on other sites More sharing options...
rsanford Posted August 29, 2011 Share Posted August 29, 2011 Beneficial example, thank you! Quote Link to comment Share on other sites More sharing options...
lucksjb Posted March 5, 2013 Share Posted March 5, 2013 How can I adjust size of column with this image ? tnx advanced Luciano Quote Link to comment Share on other sites More sharing options...
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.