edited menu code for batches