Hi Mantri Shekar,
I am an SAP internal employee and the app is yet to be released to the customer. So, I cannot share my own code. But I can share a code which is along the similar lines. If that's OK with you please respond and I will give you the code. You can contact me if you're a sap internal as well. Thanks.
Regards,
Tejas Sastry.