Widget.getChild() return the first child of a widget. But widgets are linked list elements, to retrieve next children, you can iterate like :
for (Widget widget = parentWidget.getChild(); widget != null; widget = widget.net) {
...
}
Else, to retrieve a specific widget, simple add an ID.
...
<menuItem id="getMenuItem" onAction="get">GET</menuItem>
...
And you can retrieve it from any ancestror widget like the screen for example.
Widget widget = screen.getWidget("getMenuItem");
Else again, instead of remove a widget (which is definitive), you can hide it with visible = false. Visible is an attribute, then you can update the value by a dataProvider :
...
<menuItem onAction="get">
<_visible>@{getIsVisible}</visible>
GET
</menuItem>
...
And simple change the 'getIsVisible' property value from associated dataProvider. (more info on dataProvider here)
Caution, getIsVisible property value need to be a "String" representation of a boolean : "true", or "false".