I uninstalled Windows 8 completely and then installed only "Ubuntu". Now I want to uninstall ubuntu and reinstall Windows, I dont have a live cd of ubuntu. I have my genuine windows in a flash drive (USB). Does the installation work if I format the drive from Disks option in Ubuntu?, what would be the consequence of formatting from there. Assist me with best possible solution. Thanks in advance.
It is not possible to format a hard drive you are currently booting from. You would need to use the Ubuntu live cd/usb.
You should also be able to format through the Windows installer. I've actually only once or twice in my life installed Windows so I actually have no idea about if the Windows installer has this feature but I would be seriously surprised if it doesn't.
If you want to install any Windows, you should use only your Windows' installation media. No pre-formatting using any of Ubuntu's tools should be required. Moreover: if you made the "genuine Windows in a flash drive" on your own from a pre-installed system using the Win8 backup utility, you may realize that you are not able to reinstall your Windows after formatting the drive in the past because of destroying the hidden partition on the HD. So be careful erasing your Ubuntu, you may end up with a dead computer and without any installation media.