Time for action – creating the reminder app screens

The steps shown here are going to use the standard LiveCode fields and buttons, but feel free to make your version more attractive!

  1. Create a new Mainstack, give it the name EasyReminder, and save it. Other names, such as Simple Reminders, might be more descriptive, but it would be too long a name if you're using an older iPhone.
  2. Set the card size to the size of your device. The screenshots shown in this section are based on an older iPhone-sized stack.
  3. Go to Standalone Application Settings and set the values in the same way that we did while testing the Location feature.
  4. Set the name of the first card to be home.
  5. Create a Sort by Time button, a Sort by Location button, one field named reminders, another field named data, and two buttons named Create Reminder… and Create Location….
  6. Add one more button named Delete Location or Reminder.
  7. Make sure that both the fields have their Lock text and Don't wrap box checked.
  8. You should now have a screen that looks something like the following screenshot:
    Time for action – creating the reminder app screens
  9. Make a new card and name it location.
  10. Add a field and set its contents to: Enter the latitude and longitude for this location.
  11. Add two input fields named latitude, and longitude.
  12. Create a button named Set to Current Location.

    Tip

    Avoid typos

    Although we have placed a field for you to type in the location by hand, use the Set to Current Location button if possible or at least use that at your current location to see the format that is required.

  13. Add another instructions field that says: Enter a name for this location:.
  14. Add a third input field named location name. Note that on older phones with smaller screens, this field location needs to be toward the top of the screen, so that it isn't covered by the keyboard popup.
  15. Finally, add a button named Add Location and Cancel.
  16. For this card, all the three fields need their Lock text box to be unchecked.
  17. The card should look like the following screenshot:
    Time for action – creating the reminder app screens
  18. Make a third card and name it reminder.
  19. Add two instructions fields that say: Enter a title for this reminder: and Enter a brief description:.
  20. Create two more input fields named title, and description.
  21. Create three buttons named Set Related Location, Set Date, and Set Time.
  22. Add three fields next to those buttons, which will be used to show the user that the selection they made has taken place. Name the fields location field, date field, and time field.
  23. Create a checkbox button named Play Alert Sound.
  24. Lastly, create two more buttons named Add Reminder and Cancel.
  25. Arrange all of these elements to appear as shown in the following screenshot:
    Time for action – creating the reminder app screens

What just happened?

We've made all of the screens needed for the app to function. That was the easy bit. Just wait until you see how much typing you are going to do!

Stack-level scripts

There is quite a bit of code ahead. Describing it feature by feature would require us to jump all over the place, which would add to the existing scripts in some cases and we would easily get lost in this situation. So, instead of doing it that way, we'll look at the code for each card at a time and also at the handlers that go into the stack script. It's shown here in the Time for action section, mainly to give you a break now and then! Without further ado, the stack script…

..................Content has been hidden....................

You can't read the all page of ebook, please click here login for view all page.
Reset
18.190.160.221