Changed the storeData into it's own function.

Also started to add the edit fuction.