@Lock Down : Sorry for not mentioning platform.Its windows. The commands always will be success.(99%).How to make it execute the next command after the previous one process has closed?

Thanks for your time.