updated to use do...while instead of while (basic stuff)
added Edit context menu