Changes the current element of the specified list to the given new element. This function is very useful if you want to "remember" an element, and restore it after performing other processing.
LinkedList() The name of your linked-list variable, created with the NewList function. You must include the brackets after the list name. *NewElement The new element to set as the current element for the linked-list. The element must be a pointer to another element which exists in this list. You should get this address by using the @ operator on the list name and not through any other method.
This function has no return value.
*Old_Element = @mylist() ; Get the address of the current element ResetList(mylist()) ; Perform a search for all elements named While NextElement(mylist()) ; "John" and change them to "J" If mylist()\name = "John" mylist()\name = "J" EndIf Wend ChangeCurrentElement(mylist(), *Old_Element) ; Restore previous current element (from before the search)