Why can't I get this to work? I'm trying to use a cursor and append records on it.
This is my exact code,
select ckey from treeview into cursor csrtemp
use (dbf([csrtemp])) again in 0 alias csrtable
select csrtable
use in csrtemp
nodeptr = thisform.oletreeview.selecteditem
local childnodeptr
childnodeptr = m.nodeptr.child
do while !isnull(m.childnodeptr)
append blank
replace ckey with m.childnodeptr.key
childnodeptr = m.childnodeptr.next
enddo
There is no error but I don't get the correct value for the table. Records seem to be appended every time to table csrtable, previous values are retained.
What is wrong?