YEAR 13 DIGITAL TECHNOLOGY
  • Home
  • Web Design
    • Term 1 Overview
    • Level 2 JS with HTML recap
    • Level 2 CSS Recap
    • Responsive Design
    • Javascript - Non-Core Functionality
    • Learn - Photoshop
    • User Experience Principles
    • AS91903 - Media Outcome >
      • Resources
  • Programming
    • Term 2 Overview
    • Recap Level 1
    • Recap Arrays
    • Game Organiser App
    • Objects & Classes in Javascript
    • Importing Text into Javascript
    • AS91906 - Brief
  • Databases
    • Recap - Microsoft Access
    • SQL - SELECT
    • SQL - INSERT/UPDATE/DELETE
    • SQL - JOIN
    • Forms & Advanced Queries
    • Open with main menu and DELETE
    • Documentation x7
    • Extra for experts >
      • Security Lockdown
  • External
    • Pre-exam info
    • (Optional) Reflection
  • Freyberg Digital

Open with main menu and DELETE

Opening with the main menu form

To make the Access database open with the main menu form only do the following

1.) Click File -->  Options
2.) Go to the "Current Database" tab
3.) Change the display form to the main menu form
4.) Save and close the database
​5.) Open it up again to see what happens

If you experience any issues and wish to bypass this simply hold shift when opening up the database
Picture
Picture

Qry - Delete Records

Warning - Create a backup before continuing with this task

The database owner wants to ensure that you can delete records of students that are not enrolled with the click of a button.

This is where we use queries, we can use queries to not only search for records, but we can also use them to delete records.

Task - Create a delete query to delete the currently viewed records from the manage students form.

1.) BACK UP YOUR DATABASE (You don't want to have to reinsert your records because you last data)
2.) Copy the qryStudents and rename it qryDeleteStudents
3.) Change the type of qry to "delete"
4.) Add one more field to tell the query which table to delete the records from 
(See picture below)
tblStudents.*
tableStudents
​From
Picture
Picture
Picture
You can turn off the warning with this command
DoCmd.SetWarnings False

But be sure to turn it back on afterwards.
Task - Link the query to a button

Create a button that says "Delete currently viewed data"

​Program it with this:
​DoCmd.OpenQuery "qryDeleteStudents"


To remove the error messages type this in:
​DoCmd.SetWarnings False

 DoCmd.SetWarnings True

Final Task:

Update your prisoners database with the learning from this page.
Picture
Powered by Create your own unique website with customizable templates.
  • Home
  • Web Design
    • Term 1 Overview
    • Level 2 JS with HTML recap
    • Level 2 CSS Recap
    • Responsive Design
    • Javascript - Non-Core Functionality
    • Learn - Photoshop
    • User Experience Principles
    • AS91903 - Media Outcome >
      • Resources
  • Programming
    • Term 2 Overview
    • Recap Level 1
    • Recap Arrays
    • Game Organiser App
    • Objects & Classes in Javascript
    • Importing Text into Javascript
    • AS91906 - Brief
  • Databases
    • Recap - Microsoft Access
    • SQL - SELECT
    • SQL - INSERT/UPDATE/DELETE
    • SQL - JOIN
    • Forms & Advanced Queries
    • Open with main menu and DELETE
    • Documentation x7
    • Extra for experts >
      • Security Lockdown
  • External
    • Pre-exam info
    • (Optional) Reflection
  • Freyberg Digital