I sat down today to code for about an hour. It’s one of the last days that we will have childcare, so I had to make the most of it before we hit the road again. Do you ever have a day where nothing works the way you expect it to? That’s what happened to me today. Almost like, I wish I would have never even sat down at my laptop today and attempted this, because I think I messed up more than I solved!
I dove back into my tutorial. I thought I remembered exactly where I was, but after about 20 minutes, the tutorial told me to take an action on a button that I hadn’t even created yet. Hmmm…I think I may have remembered incorrectly. So I combed back through the tutorial and figured out exactly where I left off.
The goal of today was to actually save my meals and display them in a list. Up until today, I have been working with hard-coded values behind the scenes. It was time to take the user’s input, store it in a “Meal” object, then pass it to the MealTableViewController to display it in the list.
The tutorial had me to an unwind segue, which lets you return to view controllers that already exist. So we need the unwind segue for when the user either saves the meal object, or cancels out of the “Add” process.
I keep getting errors and using the auto-correct feature that’s built into Xcode, and I think that’s been a bad idea. It’s adding code that I don’t know about, then I get even more errors. It feels like this is getting out of hand. I’ve basically accomplished nothing today. I know this is a learning opportunity, but it sucks.
I’ve tried to back out of my changes, but I’m confused where I even left off. I got desperate enough to just open the final source code of the tutorial and compare it to what I have, which is not the way I like to learn…but I think I’ve gotten myself into a hole too deep to dig out of.
Now I have to go pick up my daughter, so this problem will have to wait for another day. To calm my nerves I leave you with a picture of one of my favorite places: Arizona.