Chapter 12 - Designing Multiwindow Applications1 Chapter 12 Designing Multiwindow Applications 12.

Slides:



Advertisements
Similar presentations
1 After completing this lesson, you will be able to: Create a database. Create a table using the Table Wizard. Create and modify a table in Design view.
Advertisements

GUI Elements Session 17. Memory Upload Layout Components Button TextField TextArea Label Choice Containers Panels The applet itself.
Chapter 11 Creating Framed Layouts Principles of Web Design, 4 th Edition.
Unit 3 Graphical User Interface (GUI) Dr. Magdi AMER.
Jeopardy Objects Navigation Buttons True/False Parts of a Report Vocabulary Q $100 Q $200 Q $300 Q $400 Q $500 Q $100 Q $200 Q $300 Q $400 Q $500 Final.
UT-Space Manager. Define Rooms The Define Rooms task is used to manage your room data. 1.On the Process Navigator, click on the Space Inventory & Performance.
Guide to Oracle10G1 Introduction To Forms Builder Chapter 5.
Java Programming, 3e Concepts and Techniques Chapter 5 Arrays, Loops, and Layout Managers Using External Classes.
Microsoft Access 2003 Introduction To Microsoft Access 2003.
Create slices and hotspots Create links in Web pages Create rollovers from slices Create basic animation Add tweening symbol instances to create animation.
A Guide to Oracle9i1 Introduction To Forms Builder Chapter 5.
Swing CS-328 Dick Steflik John Margulies. Swing vs AWT AWT is Java’s original set of classes for building GUIs Uses peer components of the OS; heavyweight.
Object-Oriented Application Development Using VB.NET 1 Chapter 13 Introduction to Data Access Classes and Persistence.
Object-Oriented Application Development Using VB.NET 1 Creating a String Array Code to create a String array: ' declare a String array with 4 elements.
CS102--Object Oriented Programming Lecture 19: – The Swing Package (II) Copyright © 2008 Xiaoyan Li.
Creating a Blank Database 1. Open up Microsoft Access 2. Click on Blank document button 3. On the right panel, Specify the location for saving your database.
Chapter 13: Advanced GUI and Graphics
Chapter Day 9. © 2007 Pearson Addison-Wesley. All rights reserved4-2 Agenda Day 8 Questions from last Class?? Problem set 2 posted  10 programs from.
Object-Oriented Application Development Using VB.NET 1 Chapter 9 Implementing Association Relationships.
CS708 Fall 2004 Professor Douglas Moody –MW – 2:15-3:55 pm –Friday – 6:00-9:20 pm – – –Web Site: websupport1.citytech.cuny.edu.
Chapter 15 - Creating More Complex Database Applications 1 Chapter 15 Creating More Complex Database Applications.
Chapter 6 Graphical User Interface (GUI) and Object-Oriented Design (OOD)
Chapter 6: Graphical User Interface (GUI) and Object-Oriented Design (OOD) J ava P rogramming: Program Design Including Data Structures Program Design.
Chapter 9 - Implementing Association Relationships1 Chapter 9 Implementing Association Relationships.
Microsoft Visual Basic 2005 CHAPTER 8 Using Procedures and Exception Handling.
8 Copyright © 2004, Oracle. All rights reserved. Creating LOVs and Editors.
Chapter 3 Working with Symbols and Interactivity.
Java Programming Chapter 10 Graphical User Interfaces.
CHAPTER 9 DATABASE MANAGEMENT © Prepared By: Razif Razali.
Chapter 9: Customize! Navigating with Tabs on a Tablet App.
Microsoft Visual Basic 2012 Using Procedures and Exception Handling CHAPTER SEVEN.
Chapter 5 - Writing a Problem Domain Class Definition1 Chapter 5 Writing a Problem Domain Class Definition.
Creating a Web Site to Gather Data and Conduct Research.
Java Software Solutions Lewis and Loftus Chapter 10 1 Copyright 1997 by John Lewis and William Loftus. All rights reserved. Graphical User Interfaces --
Microsoft Office Access 2003 Số tiết: 30 tiết lý thuyết 60 tiết thực hành Giáo viên: Từ thị Xuân Hiền.
Chapter One An Introduction to Visual Basic 2010 Programming with Microsoft Visual Basic th Edition.
Key Applications Module Lesson 21 — Access Essentials
Week 11 Creating Framed Layouts Objectives Understand the benefits and drawbacks of frames Understand and use frame syntax Customize frame characteristics.
Chapter 14 - Designing Data Access Classes1 Chapter 14 Designing Data Access Classes.
Chapter 5 Quick Links Slide 2 Performance Objectives Understanding Framesets and Frames Creating Framesets and Frames Selecting Framesets and Frames Using.
Chapter 5: Windows and Frames
Lotus 认证培训 Notes Domino 6/6.5 Application Development Foundation Skills ( 610 ) Exam Number: 610 Competencies: Please see exam guide. Length:
Ch 3-4: GUI Basics Java Software Solutions Foundations of Program Design Sixth Edition by Lewis & Loftus Coming up: GUI Components.
WaveMaker Visual AJAX Studio 4.0 Training Basics: Building Your First Application Binding Basics.
Office 2003 Post-Advanced Concepts and Techniques M i c r o s o f t Access Project 7 Advanced Report and Form Techniques.
Object-Oriented Application Development Using VB.NET 1 Chapter 6 Writing a Problem Domain Class Definition.
Object-Oriented Application Development Using VB.NET 1 Chapter 6 Writing a Problem Domain Class Definition.
This eCPIC Quick Guide has been developed to assist System Administrators with creating Hierarchy Grids in eCPIC. The Hierarchy Grid functionality allows.
Unit 5, Lesson 1 Working with Databases. Objectives Identify the parts of the Access screen. Identify the parts of the Access screen. Understand the purpose.
Chapter 9 Macros And Visual Basic For Applications.
Metalib Categories Administration. 2 The MetaLib Management interface is used for set up procedures relating to categories. Using the Categories Administration.
SEEM3460 Tutorial GUI in Java. Some Basic GUI Terms Component (Control in some languages) the basic GUI unit something visible something that user can.
Programming with Java © 2002 The McGraw-Hill Companies, Inc. All rights reserved. 1 McGraw-Hill/Irwin Chapter 5 Creating Classes.
Chapter 11 - A GUI Interacting With a Problem Domain Class1 Chapter 11 A GUI Interacting With a Problem Domain Class 11.
Ajmer Singh PGT(IP) JAVA IDE Programming - I. Ajmer Singh PGT(IP) GUI (Graphical User Interface) It is an interface that uses a graphic entities along.
Copyright 2007, Paradigm Publishing Inc. ACCESS 2007 Chapter 6 BACKNEXTEND 6-1 LINKS TO OBJECTIVES Using the Report Button Using the Report Button Print.
Object-Oriented Application Development Using VB.NET 1 Chapter 9 Implementing Association Relationships.
Object-Oriented Application Development Using VB.NET 1 Chapter 11 Using Multiple Forms with Problem Domain Classes.
Chapter 10 - Writing Graphical User Interfaces1 Chapter 10 Writing Graphical User Interfaces.
Chapter 6 Graphical User Interface (GUI) and Object-Oriented Design (OOD)
Object-Oriented Application Development Using VB.NET 1 Chapter 13 Introduction to Data Access Classes and Persistence.
XP New Perspectives on Macromedia Dreamweaver MX 2004 Tutorial 5 1 Adding Shared Site Elements.
Object-Oriented Application Development Using VB.NET 1 Chapter 15 Assembling a Three-Tier Windows Application.
CSC 205 Programming II Lecture 5 AWT - I.
Graphical User Interface (pronounced "gooey")
Chap 7. Building Java Graphical User Interfaces
Graphical User Interfaces -- Introduction
Creating More Complex Database Applications
eSeries Entities By Julie Ladner
Presentation transcript:

Chapter 12 - Designing Multiwindow Applications1 Chapter 12 Designing Multiwindow Applications 12

Chapter 12 - Designing Multiwindow Applications2 Navigating Multiple Windows  You could design an application with separate stand-alone GUI classes for each task – AddCustomer, FindCustomer, AddBoat, etc.  Better approach is to link them through a main menu  Main menu displays buttons for each task

Chapter 12 - Designing Multiwindow Applications3 Designing the Main Menu  The frame instance is divided into rows using the GridLayout manager  Top row is used to display the marina’s logo  Bottom row contains a panel that uses the FlowLayout manager to place three buttons – one for each task

Chapter 12 - Designing Multiwindow Applications4 Designing the Main Menu 12

Chapter 12 - Designing Multiwindow Applications5 Designing the Main Menu  The main method is called when the class is loaded into memory  The actionPerformed method determines which button was clicked and invokes the appropriate method

Chapter 12 - Designing Multiwindow Applications6 Designing the Main Menu 12

Chapter 12 - Designing Multiwindow Applications7 Designing the Main Menu 12

Chapter 12 - Designing Multiwindow Applications8 Finding a Customer  Looks similar to the FindCustomer frame  Clicking the Close button causes the main menu to reappear  The Vector of customers is shared with the AddCustomers frame 12

Chapter 12 - Designing Multiwindow Applications9 Finding a Customer  The changes required include:  Delete the main method  When the MainMenu instantiates the FindCustomer class, it passes a reference to itself  The shutDown method in FindCustomer uses the reference to make the main menu visible  The getAll method of the Customer class is used to obtain the Vector of customers  See pp. 411 for code samples

Chapter 12 - Designing Multiwindow Applications10 Adding a Customer  The changes required include:  Delete the main method  When the MainMenu instantiates the AddCustomer class, it passes a reference to itself  The shutDown method in AddCustomer is the same as FindCustomer  See pp. 412 for code samples

Chapter 12 - Designing Multiwindow Applications11 Navigating a Problem Domain Relationship  The Customer and Boat classes have a one to one relationship  The assignBoatToCustomer method populates the reference attributes used in the Boat and Customer classes 12

Chapter 12 - Designing Multiwindow Applications12 Navigating a Problem Domain Relationship 12

Chapter 12 - Designing Multiwindow Applications13 Simulating a Customer and Boat Database  You can use a Vector class to simulate a database  You will learn more about database access in Java in Chapter 15  The Vector class is used to store Boat and Customer data  See samples codes in pp. 414

Chapter 12 - Designing Multiwindow Applications14 Adding a Customer  To add a new customer, click on the Add a Customer button on the main menu  The AddCustomer class needs the following modifications:  The caption for the Add a Customer button is changed to Add a Boat  The addCustomer method now has statements added to call AddBoat 12

Chapter 12 - Designing Multiwindow Applications15 Adding a Boat  After you enter the customer name, address, and phone number, you click addBoatButton, which invokes addCustomer to create a customer instance and display the AddBoat frame  You need to make the following changes:  The main method is deleted  When AddCustomer instantiates AddBoat, it passes a reference of itself and the newly created customer instance to the AddBoat constructor  The shutDown method in AddBoat is modified to make the AddCustomer frame visible 12

Chapter 12 - Designing Multiwindow Applications16 Adding a Boat

Chapter 12 - Designing Multiwindow Applications17 Finding a Customer and Boat  You can display a customer’s address and phone number plus their boat information together on the same frame  The frame is divided into four rows using the GridLayout manager  The first row is used for the marina logo 12

Chapter 12 - Designing Multiwindow Applications18 Finding a Customer and Boat

Chapter 12 - Designing Multiwindow Applications19 Finding a Customer and Boat  The second row contains a panel named centerPanel, which has one row and two columns  The left column contains a JList to display customer names  The right column contains a panel named centerRightPanel, which is divided into two columns  The first column holds a label to hold the customer’s name  The second column holds a label to hold the customer’s phone number

Chapter 12 - Designing Multiwindow Applications20 Finding a Customer and Boat  The third row contains a panel named lowerPanel that uses the FlowLayout manager to display a string containing the customer’s boat information  The code to display the logo and to create and display the list of customers is identical to the FindCustomer class 12

Chapter 12 - Designing Multiwindow Applications21 Finding a Customer and Boat  Two push buttons are created to the lower panel to Find and Close  The actionPerformed method is used to determine which button is clicked  The shutDown method makes the main menu visible and disposes the FindCustomerAndBoat frame

Chapter 12 - Designing Multiwindow Applications22 Finding a Customer and Boat  The findCustomer method is used to retrieve the customer name that was selected from the list  The Vector instance is called to retrieve the reference for the customer at the selected index  The getAddress and getPhoneNo methods are called to retrieve the appropriate information  The getBoat method is called to retrieve the boat information 12

Chapter 12 - Designing Multiwindow Applications23 Finding a Customer and Boat 12

Chapter 12 - Designing Multiwindow Applications24 Finding a Customer and Boat 12