There seems to be multiple problems in your code. Basically you need to clarify the object ownership issue to your self to get it work.
Firstly you are taking a pointer to a menuItem, which mean that you are getting a pointer to a onbject, which you dont own, it's still owned by your menupane, so wwhen you delete it later you are deleting something you dont own and causing a your system to crash.
secondly you are setting a bitmap and a mask for it, by first constructing two bitmap objects. So when you construct them you own them, then when you set the to be used by the menupane, the ownership is moved to the menupane. But then you say SetBitmapsOwnedExternally(), so then you keep owning the bitmaps and the menupane is merely using the pointers.
But then you go and delete the bitmaps, so if the menupane would try using the pointers they wouldn't be valid any more and your application would crash. This propably wont happen since it already crashed because of the first problem.
So the solution is easy dont delete the menuitem, dont set bitmap ownership to your self, let the menupane own it's icons and then do not delete the bitmaps, since you dont own them after you have set them to the menupane.
Easiest way to do it all would be propably to use SetIcon()-function, and you could make the icon by using CEikonEnv's CreateIconL()-function.
It seems nothing show on the emulator. Please help me.
Also, when I read the SDK for MENU_ITEM, it said it was "Withdrawn in 7.0s". Why? Is it no longer support? And how should we construct the menu?