Trees are are called outliners
Basically what you do is you hit f1, click show hide technical documentation and click mel reference, type outlinerEditor in the text field of the new screens textbox and click on outlinerEditor link then croll down the page and read the exple section wich kindly reads:
CODE
// Create a new regular outliner in its own window
//
window;
frameLayout -labelVisible false;
string $panel = outlinerPanel
;
string $outliner = outlinerPanel -query -outlinerEditor $panel
;
outlinerEditor -edit
-mainListConnection "worldList"
-selectionConnection "modelList"
-showShapes false
-showAttributes false
-showConnected false
-showAnimCurvesOnly false
-autoExpand false
-showDagOnly true
-ignoreDagHierarchy false
-expandConnections false
-showNamespace true
-showCompounds true
-showNumericAttrsOnly false
-highlightActive true
-autoSelectNewObjects false
-doNotSelectNewObjects false
-transmitFilters false
-showSetMembers true
-setFilter defaultSetFilter
$outliner;
showWindow;
a slight variation of this is the nodeOutliner command (alsi it has a example in the help files read it!), and then in maya 8.0 and above theres the general purpose psdChannelOutliner with wich you can add whatever children you want again example in the reference (bit wierd name really but its only internalkly used for psd channels tough)
List views are caled textScroll Lists! again example form manual:
CODE
window;
paneLayout;
textScrollList -numberOfRows 8 -allowMultiSelection true
-append "one" -append "two" -append "three"
-append "four" -append "five" -append "six"
-append "seven" -append "eight" -append "nine"
-append "ten" -append "eleven" -append "twelve"
-append "thirteen" -append "fourteen" -append "fifteen"
-selectItem "six"
-showIndexedItem 4;
showWindow;
i do suggest you read trough the relevant sections of the manual references by category sections.