Home > Contents > Index >
IList.moveTo
Changes the "current row" to the specified row number.
Syntax
public boolean moveTo(int i)Parameters
i
- The row number to move to, starting from 1.
Returns
Returns
true
on success,false
on failure. Success does not necessarily imply an actual move. For example, amoveTo()
the current row will succeed even though it does not actually move.Example
The following code recursively deletes the given node and its children nodes and their associated objects:
public boolean DeleteTopic(String delnode) { boolean retval = true; IList treelist; FTValList inList = new FTValList(); ics.ClearErrno(); inList.setValString("ftcmd", "getchildren"); inList.setValString("treename", treeTable); inList.setValString(Msg.parentnode, delnode); inList.setValString("join", "false"); ics.TreeManager(inList); treelist = ics.GetList(treeTable); String errno = ics.GetVar("errno"); try { for (int i=1; i <= treelist.numRows(); i++) { treelist.moveTo(i); DeleteTopic(treelist.getValue(Msg.nid)); } } catch (NoSuchFieldException e){ retval = false; } if (retval) retval = DeleteNode(delnode); return retval; }See Also
Home > Contents > Index > ![]()
Oracle JAVA Reference
Copyright (c) 2013, 2018, Oracle and/or its affiliates. All rights reserved.