04-20-2009, 11:37 AM
I tried to make a LvSetItemText based on LvGetItemText
Function LvGetItemText
I edited it like this....
Function LvSetItemText
with the calling statement
Function AttendingCommentsDlg_Trainee
but it still doesn't work.
Any help would be much appreciated. I think I am getting close!!
Stuart
Function LvGetItemText
;/
function! hlv item subitem str&s
;Gets listview control item text.
;Returns 1 if not empty, 0 if empty.
;hlv - handle.
;item - 0-based row index.
;subitem - 0-based column index.
;s - receives text.
LVITEMW li
BSTR b.alloc(260)
li.pszText=b
li.cchTextMax=260
li.iSubItem=subitem
SendMessage(hlv LVM_GETITEMTEXTW item &li)
s.ansi(b)
ret s.len!=0I edited it like this....
Function LvSetItemText
;/
function! hlv item subitem str&s
;Gets listview control item text.
;Returns 1 if not empty, 0 if empty.
;hlv - handle.
;item - 0-based row index.
;subitem - 0-based column index.
;s - supplies text.
LVITEMW li
BSTR b.alloc(260)
li.pszText=s
li.iSubItem=subitem
SendMessage(hlv LVM_SETITEMTEXTW item &li)
retwith the calling statement
Function AttendingCommentsDlg_Trainee
,,str CheckBoxYes="Yes"
,,int CheckBoxSubItem=0
,,LvSetItemText hlv RowNumber CheckBoxSubItem CheckBoxYesbut it still doesn't work.
Any help would be much appreciated. I think I am getting close!!
Stuart
