countcb wrote:
Ah. sorry. My mistake.
The parameter to the remove method is passed via the ref keyword.
That means the Remove method wants to change this iter (it will set the iter to the next valid row after it deleted the row).
But we just passed a method which will return a iter. But the remove method can't assign anything to this reutn value because it not held in a variable.
So the correct way of doing it would be:
TreeIter iter = subModel.ConvertIterToChildIter(iterSelected);
listStore.Remove(ref iter);
Already tried that but than I get 3 error messages after clicking the delete button.
Can't remember what messages but I just deleted the whole treeModelFilter. Adding new rows to the treeview didn't work either with the treemodelfilter.
Everything works now except the searchfunction but I'll found something else to get the search option working. :-)