Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Grid image in cell based on path in other cell
If you have the below grid:
Copy      Help
 c0    c1        c2
img 1|%IMG%|C:\Windows\SysWOW64\@AudioToastIcon.png
img 2|%IMG%|C:\Windows\SysWOW64\@EnrollmentToastIcon.png
img 3|%IMG%|C:\Windows\SysWOW64\@VpnToastIcon.png
img 4|%IMG%|C:\Windows\SysWOW64\@WirelessDisplayToast.png
img 5|%IMG%|C:\Windows\SysWOW64\DefaultAccountTile.png

Is it possible to populate the second column (%IMG%) with the paths from the third cell (cell 2)?
If this would take to much time then skip this, I can only consume that QM3 is an gigantic project which needs all of your attention. But if it is possible to implement an example for the above issue, then that would be very very welcome!

(The image paths used in the above and below code should be existing images available in each windows 10 professional installation)

Function images_in_grid_based_on_path_in_cell
Copy      Help
str dd=
;0 "" 0x90C80AC8 0x0 0 0 224 136 "Dialog"
;3 QM_Grid 0x56031041 0x200 1 2 222 133 "0x0,0,0,0x0,0x0[]Name,20%,7,[]Image,40%,7,[]Path,37%,7,"
;DIALOG EDITOR: "" 0x2040601 "*" "" "" ""

str controls = "3"
str qmg3x
if(!ShowDialog(dd &sub.DlgProc &controls)) ret

#sub DlgProc
function# hDlg message wParam lParam

sel message
,DlgGrid- grd.Init(hDlg 3)
,str csv_str=
,;img 1|%IMG%|C:\Windows\SysWOW64\@AudioToastIcon.png
,;img 2|%IMG%|C:\Windows\SysWOW64\@EnrollmentToastIcon.png
,;img 3|%IMG%|C:\Windows\SysWOW64\@VpnToastIcon.png
,;img 4|%IMG%|C:\Windows\SysWOW64\@WirelessDisplayToast.png
,;img 5|%IMG%|C:\Windows\SysWOW64\DefaultAccountTile.png
,ICsv- img_icsv ;; or 'tcsv._create'
,case WM_COMMAND goto messages2
sel wParam
,case IDOK
ret 1
Much work. Load all images as bitmaps and add to an imagelist. Variable row heights are not supported.
Ok, no problem had a feeling this would be a very time consuming request.

Forum Jump:

Users browsing this thread: 1 Guest(s)