working on generic code for menu click