SlideShare une entreprise Scribd logo
1  sur  23
CIS-245 Final Review
Form Design Guidelines Provide meaningful title Organize fields logically Use appealing form layout Include familiar field labels Be consistent with terminology and abbreviations
Form Design Guidelines – 2 Allow for convenient cursor movement Prevent and correct errors Include explanatory messages for fields
Using Forms Bound form has a Record Source  Displays data from fields in record source Unbound forms  Do not have record source Designed to help users navigate through database
Subforms Subform is a form embedded in another form Primary form (called main form) Usually has one-to-many relationship with data in subform Main form and subform linked  Subform displays only records that related to current record in main form
Command Buttons Command buttons  Users click to perform common tasks Can contain Text, Icons, Graphics Create Using Command Button Wizard  By adding button to form then setting properties Be consistent when creating command buttons Location on form Order
Tab Order and Tab Stop Form created with form tool or Form Wizard  Places fields in order they appear in table design After fields are rearranged for more logical data entry, correct tab order Test each form!
Parameter Queries Way to change query ‘on the fly’ Can use prompt for user Can get information from form controls Forms!FormName!ControlName
Using Lists List controls: set rowsource Listbox Combobox Forms: set recordsource Reports: set recordsource Remember to requery! Find right event to respond to
Reports Grouping: When RecordSource has all of the data needed, and all needed records are included Sub-reports: When need data that’s not part of RecordSource OR RecordSource wouldn’t include all records Use CanGrow, CanShrink
Report Events Limited number Most deal with laying out and formatting data Use NoData instead of showing an empty report
Domain Functions Also called Domain Aggregate Functions Allows creation of summary information without a query DCount DSum DMax
Domain Function Syntax Need a field to work with Need to specify where the field is found (table or query) Can optionally add a ‘where’ clause to limit the records included DCount(“PatientID”,”Visits”,”Total<100”)
Event-driven Applications Have to choose which event to respond to Events can be generated by the user or changes in data or objects
Visual Basic for Applications Many commands start with ‘DoCmd’ Code is organized into procedures Property Procedures Functions Subroutines Procedures can use arguments to pass data Use With … End With when referring to an object several times
Bang & Dot Operators Two methods to reference “owned” objects Use ! (bang) if referring to a control in a query In code, can use both ! (bang) and . (dot) If referring to fields in a recordsource, use ! If referring to controls can use either
Using Variables Scope: How long a variable lasts and where it can be accessed Forcing declaration: Option Explicit Objects: Can represent more than just basic data, can create object variables Need to create an instance – New keyword Use Set to make an assignment
Collections Most objects are members of some group A collection is a group of like objects Forms collection holds all forms A form’s controls collection holds all controls that belong to that form
Decision-Making Branching (what’s next?) If-Then Select Case Loops (repeating a task) For … Next For .. Each Do While Do Until
Where Condition Optional argument for many commands When opening a form or report, can limit the records to be used, even if the recordsource is a table DoCmd.OpenForm “frmName”,,,”field=1”
Error Handling Logic errors Runs but doesn’t give the right results Syntax errors Compiler can’t process your code Run-time errors Problem happens during execution Use On Error to respond to
Data Models ADO: ActiveX Data Objects For working with data Typically used in code DAO: Data Access Objects For working with data Used in Forms, Reports by Access ADOX: ADO Extensions For working with database For security and database
ADO Principal Objects Connection: ‘pipe’ for moving data Command: what data to work with Recordset: local copy of data from a table or query

Contenu connexe

En vedette

Thiết kế thi công tiểu cảnh sân vườn
Thiết kế thi công tiểu cảnh sân vườnThiết kế thi công tiểu cảnh sân vườn
Thiết kế thi công tiểu cảnh sân vườnPhương Anh Construction
 
Success Factors of IT projects
Success Factors of IT projectsSuccess Factors of IT projects
Success Factors of IT projectsrajeshrvth60
 
Ashish sharma(IT Ist Year Student Work)
Ashish sharma(IT Ist Year Student Work)Ashish sharma(IT Ist Year Student Work)
Ashish sharma(IT Ist Year Student Work)dezyneecole
 
Gaining Audience Feedback
Gaining Audience FeedbackGaining Audience Feedback
Gaining Audience Feedbackdaniyal05
 
Plaquette utilisateurs Evolis 2016 david hardy
Plaquette utilisateurs Evolis 2016   david hardyPlaquette utilisateurs Evolis 2016   david hardy
Plaquette utilisateurs Evolis 2016 david hardyDavid HARDY
 
Durisol vahelaed
Durisol vahelaedDurisol vahelaed
Durisol vahelaedKoduinfo
 
Steico sõlmed
Steico sõlmedSteico sõlmed
Steico sõlmedKoduinfo
 
Durisol ja STEICO
Durisol ja STEICODurisol ja STEICO
Durisol ja STEICOKoduinfo
 
Durisol sõlmed
Durisol sõlmedDurisol sõlmed
Durisol sõlmedKoduinfo
 
Treball cooperatiu
Treball cooperatiuTreball cooperatiu
Treball cooperatiuRocio Avila
 
Javascript - Essentials
Javascript - EssentialsJavascript - Essentials
Javascript - EssentialsMuhammad Ahmed
 
Employment salary
Employment salaryEmployment salary
Employment salarySugantha T
 

En vedette (20)

Thiết kế thi công tiểu cảnh sân vườn
Thiết kế thi công tiểu cảnh sân vườnThiết kế thi công tiểu cảnh sân vườn
Thiết kế thi công tiểu cảnh sân vườn
 
Success Factors of IT projects
Success Factors of IT projectsSuccess Factors of IT projects
Success Factors of IT projects
 
Ashish sharma(IT Ist Year Student Work)
Ashish sharma(IT Ist Year Student Work)Ashish sharma(IT Ist Year Student Work)
Ashish sharma(IT Ist Year Student Work)
 
Gaining Audience Feedback
Gaining Audience FeedbackGaining Audience Feedback
Gaining Audience Feedback
 
Medical facilities
Medical facilitiesMedical facilities
Medical facilities
 
81296 de corazon
81296 de corazon81296 de corazon
81296 de corazon
 
48861875 2-d-i-akbid
48861875 2-d-i-akbid48861875 2-d-i-akbid
48861875 2-d-i-akbid
 
STEICO
STEICOSTEICO
STEICO
 
Akcijos universitetuose sarasas
Akcijos universitetuose sarasasAkcijos universitetuose sarasas
Akcijos universitetuose sarasas
 
Plaquette utilisateurs Evolis 2016 david hardy
Plaquette utilisateurs Evolis 2016   david hardyPlaquette utilisateurs Evolis 2016   david hardy
Plaquette utilisateurs Evolis 2016 david hardy
 
Durisol vahelaed
Durisol vahelaedDurisol vahelaed
Durisol vahelaed
 
Steico sõlmed
Steico sõlmedSteico sõlmed
Steico sõlmed
 
Durisol ja STEICO
Durisol ja STEICODurisol ja STEICO
Durisol ja STEICO
 
Durisol sõlmed
Durisol sõlmedDurisol sõlmed
Durisol sõlmed
 
E syariah
E syariahE syariah
E syariah
 
Treball cooperatiu
Treball cooperatiuTreball cooperatiu
Treball cooperatiu
 
Classe puzzle
Classe puzzleClasse puzzle
Classe puzzle
 
Javascript - Essentials
Javascript - EssentialsJavascript - Essentials
Javascript - Essentials
 
public private partnership
 public private partnership public private partnership
public private partnership
 
Employment salary
Employment salaryEmployment salary
Employment salary
 

Similaire à Cis245 finalreview

AIA101.3.Access Reports And Forms
AIA101.3.Access Reports And FormsAIA101.3.Access Reports And Forms
AIA101.3.Access Reports And FormsDan D'Urso
 
MS Access – Part 1 (One Day Workshop)
MS Access – Part 1 (One Day Workshop)MS Access – Part 1 (One Day Workshop)
MS Access – Part 1 (One Day Workshop)Khader Shaik
 
Program logic and design
Program logic and designProgram logic and design
Program logic and designChaffey College
 
Ten Steps To Empowerment
Ten Steps To EmpowermentTen Steps To Empowerment
Ten Steps To EmpowermentMohan Dutt
 
Introduction to programming by MUFIX Commnity
Introduction to programming by MUFIX CommnityIntroduction to programming by MUFIX Commnity
Introduction to programming by MUFIX Commnitymazenet
 
Demo Guidebook 040110
Demo Guidebook 040110Demo Guidebook 040110
Demo Guidebook 040110Brad Ganas
 
essentialofdatabasedesign-141203001046-conversion-gate01.pdf
essentialofdatabasedesign-141203001046-conversion-gate01.pdfessentialofdatabasedesign-141203001046-conversion-gate01.pdf
essentialofdatabasedesign-141203001046-conversion-gate01.pdfAlfiaAnsari2
 
Programming Without Coding Technology (PWCT) Environment
Programming Without Coding Technology (PWCT) EnvironmentProgramming Without Coding Technology (PWCT) Environment
Programming Without Coding Technology (PWCT) EnvironmentMahmoud Samir Fayed
 
Addmi 02-addm overview
Addmi 02-addm overviewAddmi 02-addm overview
Addmi 02-addm overviewodanyboy
 
Data access best practices
Data access best practicesData access best practices
Data access best practicesGieno Miao
 
Using the Kentico CMS API
Using the Kentico CMS APIUsing the Kentico CMS API
Using the Kentico CMS APIThomas Robbins
 
Sas UTR How To Create Your UTRs Sep2009
Sas UTR How To Create Your UTRs Sep2009Sas UTR How To Create Your UTRs Sep2009
Sas UTR How To Create Your UTRs Sep2009praack
 
Web based database application design using vb.net and sql server
Web based database application design using vb.net and sql serverWeb based database application design using vb.net and sql server
Web based database application design using vb.net and sql serverAmmara Arooj
 

Similaire à Cis245 finalreview (20)

Dbms fast track 2/3
Dbms fast track 2/3Dbms fast track 2/3
Dbms fast track 2/3
 
AIA101.3.Access Reports And Forms
AIA101.3.Access Reports And FormsAIA101.3.Access Reports And Forms
AIA101.3.Access Reports And Forms
 
MS Access – Part 1 (One Day Workshop)
MS Access – Part 1 (One Day Workshop)MS Access – Part 1 (One Day Workshop)
MS Access – Part 1 (One Day Workshop)
 
Program logic and design
Program logic and designProgram logic and design
Program logic and design
 
Les02
Les02Les02
Les02
 
Ten Steps To Empowerment
Ten Steps To EmpowermentTen Steps To Empowerment
Ten Steps To Empowerment
 
Salesforce
SalesforceSalesforce
Salesforce
 
Introduction To Programming (2009 2010)
Introduction To Programming (2009 2010)Introduction To Programming (2009 2010)
Introduction To Programming (2009 2010)
 
Introduction to programming by MUFIX Commnity
Introduction to programming by MUFIX CommnityIntroduction to programming by MUFIX Commnity
Introduction to programming by MUFIX Commnity
 
Demo Guidebook 040110
Demo Guidebook 040110Demo Guidebook 040110
Demo Guidebook 040110
 
Jmp108
Jmp108Jmp108
Jmp108
 
essentialofdatabasedesign-141203001046-conversion-gate01.pdf
essentialofdatabasedesign-141203001046-conversion-gate01.pdfessentialofdatabasedesign-141203001046-conversion-gate01.pdf
essentialofdatabasedesign-141203001046-conversion-gate01.pdf
 
Programming Without Coding Technology (PWCT) Environment
Programming Without Coding Technology (PWCT) EnvironmentProgramming Without Coding Technology (PWCT) Environment
Programming Without Coding Technology (PWCT) Environment
 
Test
TestTest
Test
 
Addmi 02-addm overview
Addmi 02-addm overviewAddmi 02-addm overview
Addmi 02-addm overview
 
Data access best practices
Data access best practicesData access best practices
Data access best practices
 
Using the Kentico CMS API
Using the Kentico CMS APIUsing the Kentico CMS API
Using the Kentico CMS API
 
Sas UTR How To Create Your UTRs Sep2009
Sas UTR How To Create Your UTRs Sep2009Sas UTR How To Create Your UTRs Sep2009
Sas UTR How To Create Your UTRs Sep2009
 
Intro to Application Express
Intro to Application ExpressIntro to Application Express
Intro to Application Express
 
Web based database application design using vb.net and sql server
Web based database application design using vb.net and sql serverWeb based database application design using vb.net and sql server
Web based database application design using vb.net and sql server
 

Plus de Randy Riness @ South Puget Sound Community College

Plus de Randy Riness @ South Puget Sound Community College (20)

Stored procedures
Stored proceduresStored procedures
Stored procedures
 
3 sql overview
3 sql overview3 sql overview
3 sql overview
 
Normalization
NormalizationNormalization
Normalization
 
CIS160 final review
CIS160 final reviewCIS160 final review
CIS160 final review
 
SQL Constraints
SQL ConstraintsSQL Constraints
SQL Constraints
 
CIS145 Final Review
CIS145 Final ReviewCIS145 Final Review
CIS145 Final Review
 
Cis166 Final Review C#
Cis166 Final Review C#Cis166 Final Review C#
Cis166 Final Review C#
 
Classes and Objects
Classes and ObjectsClasses and Objects
Classes and Objects
 
CIS245 sql
CIS245 sqlCIS245 sql
CIS245 sql
 
Cis245 Midterm Review
Cis245 Midterm ReviewCis245 Midterm Review
Cis245 Midterm Review
 
CSS
CSSCSS
CSS
 
XPath
XPathXPath
XPath
 
XSLT Overview
XSLT OverviewXSLT Overview
XSLT Overview
 
Views
ViewsViews
Views
 
CIS282 Midterm review
CIS282 Midterm reviewCIS282 Midterm review
CIS282 Midterm review
 
Schemas 2 - Restricting Values
Schemas 2 - Restricting ValuesSchemas 2 - Restricting Values
Schemas 2 - Restricting Values
 
CIS 145 test 1 review
CIS 145 test 1 reviewCIS 145 test 1 review
CIS 145 test 1 review
 
XML schemas
XML schemasXML schemas
XML schemas
 
Document type definitions part 2
Document type definitions part 2Document type definitions part 2
Document type definitions part 2
 
Document type definitions part 1
Document type definitions part 1Document type definitions part 1
Document type definitions part 1
 

Dernier

Advanced Views - Calendar View in Odoo 17
Advanced Views - Calendar View in Odoo 17Advanced Views - Calendar View in Odoo 17
Advanced Views - Calendar View in Odoo 17Celine George
 
SOCIAL AND HISTORICAL CONTEXT - LFTVD.pptx
SOCIAL AND HISTORICAL CONTEXT - LFTVD.pptxSOCIAL AND HISTORICAL CONTEXT - LFTVD.pptx
SOCIAL AND HISTORICAL CONTEXT - LFTVD.pptxiammrhaywood
 
Separation of Lanthanides/ Lanthanides and Actinides
Separation of Lanthanides/ Lanthanides and ActinidesSeparation of Lanthanides/ Lanthanides and Actinides
Separation of Lanthanides/ Lanthanides and ActinidesFatimaKhan178732
 
The basics of sentences session 2pptx copy.pptx
The basics of sentences session 2pptx copy.pptxThe basics of sentences session 2pptx copy.pptx
The basics of sentences session 2pptx copy.pptxheathfieldcps1
 
URLs and Routing in the Odoo 17 Website App
URLs and Routing in the Odoo 17 Website AppURLs and Routing in the Odoo 17 Website App
URLs and Routing in the Odoo 17 Website AppCeline George
 
A Critique of the Proposed National Education Policy Reform
A Critique of the Proposed National Education Policy ReformA Critique of the Proposed National Education Policy Reform
A Critique of the Proposed National Education Policy ReformChameera Dedduwage
 
Measures of Central Tendency: Mean, Median and Mode
Measures of Central Tendency: Mean, Median and ModeMeasures of Central Tendency: Mean, Median and Mode
Measures of Central Tendency: Mean, Median and ModeThiyagu K
 
Mastering the Unannounced Regulatory Inspection
Mastering the Unannounced Regulatory InspectionMastering the Unannounced Regulatory Inspection
Mastering the Unannounced Regulatory InspectionSafetyChain Software
 
How to Make a Pirate ship Primary Education.pptx
How to Make a Pirate ship Primary Education.pptxHow to Make a Pirate ship Primary Education.pptx
How to Make a Pirate ship Primary Education.pptxmanuelaromero2013
 
BASLIQ CURRENT LOOKBOOK LOOKBOOK(1) (1).pdf
BASLIQ CURRENT LOOKBOOK  LOOKBOOK(1) (1).pdfBASLIQ CURRENT LOOKBOOK  LOOKBOOK(1) (1).pdf
BASLIQ CURRENT LOOKBOOK LOOKBOOK(1) (1).pdfSoniaTolstoy
 
Kisan Call Centre - To harness potential of ICT in Agriculture by answer farm...
Kisan Call Centre - To harness potential of ICT in Agriculture by answer farm...Kisan Call Centre - To harness potential of ICT in Agriculture by answer farm...
Kisan Call Centre - To harness potential of ICT in Agriculture by answer farm...Krashi Coaching
 
Z Score,T Score, Percential Rank and Box Plot Graph
Z Score,T Score, Percential Rank and Box Plot GraphZ Score,T Score, Percential Rank and Box Plot Graph
Z Score,T Score, Percential Rank and Box Plot GraphThiyagu K
 
Introduction to ArtificiaI Intelligence in Higher Education
Introduction to ArtificiaI Intelligence in Higher EducationIntroduction to ArtificiaI Intelligence in Higher Education
Introduction to ArtificiaI Intelligence in Higher Educationpboyjonauth
 
Paris 2024 Olympic Geographies - an activity
Paris 2024 Olympic Geographies - an activityParis 2024 Olympic Geographies - an activity
Paris 2024 Olympic Geographies - an activityGeoBlogs
 
Hybridoma Technology ( Production , Purification , and Application )
Hybridoma Technology  ( Production , Purification , and Application  ) Hybridoma Technology  ( Production , Purification , and Application  )
Hybridoma Technology ( Production , Purification , and Application ) Sakshi Ghasle
 
Privatization and Disinvestment - Meaning, Objectives, Advantages and Disadva...
Privatization and Disinvestment - Meaning, Objectives, Advantages and Disadva...Privatization and Disinvestment - Meaning, Objectives, Advantages and Disadva...
Privatization and Disinvestment - Meaning, Objectives, Advantages and Disadva...RKavithamani
 
Nutritional Needs Presentation - HLTH 104
Nutritional Needs Presentation - HLTH 104Nutritional Needs Presentation - HLTH 104
Nutritional Needs Presentation - HLTH 104misteraugie
 
Arihant handbook biology for class 11 .pdf
Arihant handbook biology for class 11 .pdfArihant handbook biology for class 11 .pdf
Arihant handbook biology for class 11 .pdfchloefrazer622
 

Dernier (20)

Advanced Views - Calendar View in Odoo 17
Advanced Views - Calendar View in Odoo 17Advanced Views - Calendar View in Odoo 17
Advanced Views - Calendar View in Odoo 17
 
SOCIAL AND HISTORICAL CONTEXT - LFTVD.pptx
SOCIAL AND HISTORICAL CONTEXT - LFTVD.pptxSOCIAL AND HISTORICAL CONTEXT - LFTVD.pptx
SOCIAL AND HISTORICAL CONTEXT - LFTVD.pptx
 
Separation of Lanthanides/ Lanthanides and Actinides
Separation of Lanthanides/ Lanthanides and ActinidesSeparation of Lanthanides/ Lanthanides and Actinides
Separation of Lanthanides/ Lanthanides and Actinides
 
The basics of sentences session 2pptx copy.pptx
The basics of sentences session 2pptx copy.pptxThe basics of sentences session 2pptx copy.pptx
The basics of sentences session 2pptx copy.pptx
 
URLs and Routing in the Odoo 17 Website App
URLs and Routing in the Odoo 17 Website AppURLs and Routing in the Odoo 17 Website App
URLs and Routing in the Odoo 17 Website App
 
A Critique of the Proposed National Education Policy Reform
A Critique of the Proposed National Education Policy ReformA Critique of the Proposed National Education Policy Reform
A Critique of the Proposed National Education Policy Reform
 
Measures of Central Tendency: Mean, Median and Mode
Measures of Central Tendency: Mean, Median and ModeMeasures of Central Tendency: Mean, Median and Mode
Measures of Central Tendency: Mean, Median and Mode
 
INDIA QUIZ 2024 RLAC DELHI UNIVERSITY.pptx
INDIA QUIZ 2024 RLAC DELHI UNIVERSITY.pptxINDIA QUIZ 2024 RLAC DELHI UNIVERSITY.pptx
INDIA QUIZ 2024 RLAC DELHI UNIVERSITY.pptx
 
Mastering the Unannounced Regulatory Inspection
Mastering the Unannounced Regulatory InspectionMastering the Unannounced Regulatory Inspection
Mastering the Unannounced Regulatory Inspection
 
How to Make a Pirate ship Primary Education.pptx
How to Make a Pirate ship Primary Education.pptxHow to Make a Pirate ship Primary Education.pptx
How to Make a Pirate ship Primary Education.pptx
 
BASLIQ CURRENT LOOKBOOK LOOKBOOK(1) (1).pdf
BASLIQ CURRENT LOOKBOOK  LOOKBOOK(1) (1).pdfBASLIQ CURRENT LOOKBOOK  LOOKBOOK(1) (1).pdf
BASLIQ CURRENT LOOKBOOK LOOKBOOK(1) (1).pdf
 
Código Creativo y Arte de Software | Unidad 1
Código Creativo y Arte de Software | Unidad 1Código Creativo y Arte de Software | Unidad 1
Código Creativo y Arte de Software | Unidad 1
 
Kisan Call Centre - To harness potential of ICT in Agriculture by answer farm...
Kisan Call Centre - To harness potential of ICT in Agriculture by answer farm...Kisan Call Centre - To harness potential of ICT in Agriculture by answer farm...
Kisan Call Centre - To harness potential of ICT in Agriculture by answer farm...
 
Z Score,T Score, Percential Rank and Box Plot Graph
Z Score,T Score, Percential Rank and Box Plot GraphZ Score,T Score, Percential Rank and Box Plot Graph
Z Score,T Score, Percential Rank and Box Plot Graph
 
Introduction to ArtificiaI Intelligence in Higher Education
Introduction to ArtificiaI Intelligence in Higher EducationIntroduction to ArtificiaI Intelligence in Higher Education
Introduction to ArtificiaI Intelligence in Higher Education
 
Paris 2024 Olympic Geographies - an activity
Paris 2024 Olympic Geographies - an activityParis 2024 Olympic Geographies - an activity
Paris 2024 Olympic Geographies - an activity
 
Hybridoma Technology ( Production , Purification , and Application )
Hybridoma Technology  ( Production , Purification , and Application  ) Hybridoma Technology  ( Production , Purification , and Application  )
Hybridoma Technology ( Production , Purification , and Application )
 
Privatization and Disinvestment - Meaning, Objectives, Advantages and Disadva...
Privatization and Disinvestment - Meaning, Objectives, Advantages and Disadva...Privatization and Disinvestment - Meaning, Objectives, Advantages and Disadva...
Privatization and Disinvestment - Meaning, Objectives, Advantages and Disadva...
 
Nutritional Needs Presentation - HLTH 104
Nutritional Needs Presentation - HLTH 104Nutritional Needs Presentation - HLTH 104
Nutritional Needs Presentation - HLTH 104
 
Arihant handbook biology for class 11 .pdf
Arihant handbook biology for class 11 .pdfArihant handbook biology for class 11 .pdf
Arihant handbook biology for class 11 .pdf
 

Cis245 finalreview

  • 2. Form Design Guidelines Provide meaningful title Organize fields logically Use appealing form layout Include familiar field labels Be consistent with terminology and abbreviations
  • 3. Form Design Guidelines – 2 Allow for convenient cursor movement Prevent and correct errors Include explanatory messages for fields
  • 4. Using Forms Bound form has a Record Source Displays data from fields in record source Unbound forms Do not have record source Designed to help users navigate through database
  • 5. Subforms Subform is a form embedded in another form Primary form (called main form) Usually has one-to-many relationship with data in subform Main form and subform linked Subform displays only records that related to current record in main form
  • 6. Command Buttons Command buttons Users click to perform common tasks Can contain Text, Icons, Graphics Create Using Command Button Wizard By adding button to form then setting properties Be consistent when creating command buttons Location on form Order
  • 7. Tab Order and Tab Stop Form created with form tool or Form Wizard Places fields in order they appear in table design After fields are rearranged for more logical data entry, correct tab order Test each form!
  • 8. Parameter Queries Way to change query ‘on the fly’ Can use prompt for user Can get information from form controls Forms!FormName!ControlName
  • 9. Using Lists List controls: set rowsource Listbox Combobox Forms: set recordsource Reports: set recordsource Remember to requery! Find right event to respond to
  • 10. Reports Grouping: When RecordSource has all of the data needed, and all needed records are included Sub-reports: When need data that’s not part of RecordSource OR RecordSource wouldn’t include all records Use CanGrow, CanShrink
  • 11. Report Events Limited number Most deal with laying out and formatting data Use NoData instead of showing an empty report
  • 12. Domain Functions Also called Domain Aggregate Functions Allows creation of summary information without a query DCount DSum DMax
  • 13. Domain Function Syntax Need a field to work with Need to specify where the field is found (table or query) Can optionally add a ‘where’ clause to limit the records included DCount(“PatientID”,”Visits”,”Total<100”)
  • 14. Event-driven Applications Have to choose which event to respond to Events can be generated by the user or changes in data or objects
  • 15. Visual Basic for Applications Many commands start with ‘DoCmd’ Code is organized into procedures Property Procedures Functions Subroutines Procedures can use arguments to pass data Use With … End With when referring to an object several times
  • 16. Bang & Dot Operators Two methods to reference “owned” objects Use ! (bang) if referring to a control in a query In code, can use both ! (bang) and . (dot) If referring to fields in a recordsource, use ! If referring to controls can use either
  • 17. Using Variables Scope: How long a variable lasts and where it can be accessed Forcing declaration: Option Explicit Objects: Can represent more than just basic data, can create object variables Need to create an instance – New keyword Use Set to make an assignment
  • 18. Collections Most objects are members of some group A collection is a group of like objects Forms collection holds all forms A form’s controls collection holds all controls that belong to that form
  • 19. Decision-Making Branching (what’s next?) If-Then Select Case Loops (repeating a task) For … Next For .. Each Do While Do Until
  • 20. Where Condition Optional argument for many commands When opening a form or report, can limit the records to be used, even if the recordsource is a table DoCmd.OpenForm “frmName”,,,”field=1”
  • 21. Error Handling Logic errors Runs but doesn’t give the right results Syntax errors Compiler can’t process your code Run-time errors Problem happens during execution Use On Error to respond to
  • 22. Data Models ADO: ActiveX Data Objects For working with data Typically used in code DAO: Data Access Objects For working with data Used in Forms, Reports by Access ADOX: ADO Extensions For working with database For security and database
  • 23. ADO Principal Objects Connection: ‘pipe’ for moving data Command: what data to work with Recordset: local copy of data from a table or query