adding hierarchical menu sample code