Loading...
 

ResetWindow

ResetWindow

ResetWindow(windowID, childID), ResetWindow(windowID), ResetWindow(, childID), ResetWindow

Parameters: Identifier of a Windows and an object box or header

Stack
Stack Position Description
Stack(In) Top -
Stack(Out) Top -

The specified object box is reset with this command, i.e. it is restored to the state it was in before the INITIALIZE.
So it is emptied, any changes to the headers are undone, the formats and sorting criteria are completely deleted, all iterators are terminated and so on.

If a header is passed, only the headers of it are reset, e.g. a manipulation with PutValue on one of its sub-Windows objects is undone.

ResetWindow can be called with any other interface object. If it is neither a ListBox nor a header, there is no change. INITIALIZE is not triggered.

// in the window menu definition switchable list formats Define(SetListBox) [ "CX_COMPOUND_TXN::uniqueID" HEADER T("Nummer", "ID") ] SetFormat(, ListBox) [ "CX_COMPOUND_TXN::comment" HEADER T("Kommentar", "Comment") COLOR LIGHTRED ] SetFormat(, ListBox) ; Define(SetListBoxEdited) [ "CX_COMPOUND_TXN::orderTypeEnum" HEADER T("Typ", "Type") ] SetFormat(, ListBox) [ "CX_COMPOUND_TXN::net.value" COLOR BLUE JUSTIFY_RIGHT HEADER T("Wert", "Value") ] SetFormat(, ListBox) ; ... Item(AlternativeListFormatItem, T("Altern. Listenformat", "Alt. list format")) { Item(DefaultFormatItem, T("Standard", "Default")) [ SELECT: ResetWindow(, ListBox) // Reset the list to set a new format on it! SetListBox // Call macro to set the new formats! ] Item(DefaultFormatItem, T("Angepasst", "Edited")) [ SELECT: ResetWindow(, ListBox) // Reset the list to set a new format on it! SetListBoxEdited ] } ...