1 Northwind Traders Order Entry. 2 Northwind Traders Call Center Add an Order Entry capability to the Northwind Traders Call Center application. Start.

Slides:



Advertisements
Similar presentations
Numbers Treasure Hunt Following each question, click on the answer. If correct, the next page will load with a graphic first – these can be used to check.
Advertisements

Copyright © 2008 Pearson Education, Inc. Publishing as Pearson Addison-Wesley Chapter 2 Introduction to XHTML Programming the World Wide Web Fourth edition.
1
Feichter_DPG-SYKL03_Bild-01. Feichter_DPG-SYKL03_Bild-02.
© 2008 Pearson Addison Wesley. All rights reserved Chapter Seven Costs.
Copyright © 2003 Pearson Education, Inc. Slide 1 Computer Systems Organization & Architecture Chapters 8-12 John D. Carpinelli.
Chapter 1 The Study of Body Function Image PowerPoint
Copyright © 2011, Elsevier Inc. All rights reserved. Chapter 6 Author: Julia Richards and R. Scott Hawley.
Author: Julia Richards and R. Scott Hawley
1 Copyright © 2013 Elsevier Inc. All rights reserved. Appendix 01.
Properties Use, share, or modify this drill on mathematic properties. There is too much material for a single class, so you’ll have to select for your.
UNITED NATIONS Shipment Details Report – January 2006.
RXQ Customer Enrollment Using a Registration Agent (RA) Process Flow Diagram (Move-In) Customer Supplier Customer authorizes Enrollment ( )
We need a common denominator to add these fractions.
1 RA I Sub-Regional Training Seminar on CLIMAT&CLIMAT TEMP Reporting Casablanca, Morocco, 20 – 22 December 2005 Status of observing programmes in RA I.
Properties of Real Numbers CommutativeAssociativeDistributive Identity + × Inverse + ×
Exit a Customer Chapter 8. Exit a Customer 8-2 Objectives Perform exit summary process consisting of the following steps: Review service records Close.
Local Customization Chapter 2. Local Customization 2-2 Objectives Customization Considerations Types of Data Elements Location for Locally Defined Data.
Create an Application Title 1D - Dislocated Worker Chapter 9.
Process a Customer Chapter 2. Process a Customer 2-2 Objectives Understand what defines a Customer Learn how to check for an existing Customer Learn how.
Custom Statutory Programs Chapter 3. Customary Statutory Programs and Titles 3-2 Objectives Add Local Statutory Programs Create Customer Application For.
Custom Services and Training Provider Details Chapter 4.
FACTORING ax2 + bx + c Think “unfoil” Work down, Show all steps.
Year 6 mental test 5 second questions
Year 6 mental test 10 second questions
Mike Scott University of Texas at Austin
1 Click here to End Presentation Software: Installation and Updates Internet Download CD release NACIS Updates.
Excel Functions. Part 1. Introduction 2 An Excel function is a formula or a procedure that is performed in the Visual Basic environment, outside the.
REVIEW: Arthropod ID. 1. Name the subphylum. 2. Name the subphylum. 3. Name the order.
PP Test Review Sections 6-1 to 6-6
WebCafé Slide No:1 World Cyber Cafe Association Brings to You Webcafe A Cyber Café Management Software A Software That Will Boost Your Efficiency For Managing.
EU market situation for eggs and poultry Management Committee 20 October 2011.
© Paradigm Publishing, Inc Access 2010 Level 1 Unit 1Creating Tables and Queries Chapter 2Creating Relationships between Tables.
Vanderbilt Business Objects Users Group 1 Reporting Techniques & Formatting Beginning & Advanced.
EIS Bridge Tool and Staging Tables September 1, 2009 Instructor: Way Poteat Slide: 1.
Bellwork Do the following problem on a ½ sheet of paper and turn in.
© Copyright by Deitel & Associates, Inc. and Pearson Education Inc. All Rights Reserved. 1 Outline 24.1 Test-Driving the Ticket Information Application.
VOORBLAD.
Benchmark Series Microsoft Excel 2013 Level 2
1 public class Newton { public static double sqrt(double c) { double epsilon = 1E-15; if (c < 0) return Double.NaN; double t = c; while (Math.abs(t - c/t)
Sample Service Screenshots Enterprise Cloud Service 11.3.
Copyright © 2012, Elsevier Inc. All rights Reserved. 1 Chapter 7 Modeling Structure with Blocks.
1 RA III - Regional Training Seminar on CLIMAT&CLIMAT TEMP Reporting Buenos Aires, Argentina, 25 – 27 October 2006 Status of observing programmes in RA.
Factor P 16 8(8-5ab) 4(d² + 4) 3rs(2r – s) 15cd(1 + 2cd) 8(4a² + 3b²)
Basel-ICU-Journal Challenge18/20/ Basel-ICU-Journal Challenge8/20/2014.
1..
CONTROL VISION Set-up. Step 1 Step 2 Step 3 Step 5 Step 4.
© 2012 National Heart Foundation of Australia. Slide 2.
Adding Up In Chunks.
Understanding Generalist Practice, 5e, Kirst-Ashman/Hull
1 10 pt 15 pt 20 pt 25 pt 5 pt 10 pt 15 pt 20 pt 25 pt 5 pt 10 pt 15 pt 20 pt 25 pt 5 pt 10 pt 15 pt 20 pt 25 pt 5 pt 10 pt 15 pt 20 pt 25 pt 5 pt Synthetic.
1 How Do I Order From.decimal? Rev 05/04/09 This instructional training document may be updated at anytime. Please visit and check the.
Note to the teacher: Was 28. A. to B. you C. said D. on Note to the teacher: Make this slide correct answer be C and sound to be “said”. to said you on.
Model and Relationships 6 M 1 M M M M M M M M M M M M M M M M
25 seconds left…...
Analyzing Genes and Genomes
©Brooks/Cole, 2001 Chapter 12 Derived Types-- Enumerated, Structure and Union.
Essential Cell Biology
Intracellular Compartments and Transport
PSSA Preparation.
Essential Cell Biology
Immunobiology: The Immune System in Health & Disease Sixth Edition
Energy Generation in Mitochondria and Chlorplasts
Murach’s OS/390 and z/OS JCLChapter 16, Slide 1 © 2002, Mike Murach & Associates, Inc.
Windfall Web Throughout this slide show there will be hyperlinks (highlighted in blue). Follow the hyperlinks to navigate to the specified Topic or Figure.

Presentation transcript:

1 Northwind Traders Order Entry

2 Northwind Traders Call Center Add an Order Entry capability to the Northwind Traders Call Center application. Start with the solution for Project 6 Select Customer Downloads/Project_Solutions/ File P6_Select_Customer.zip Downloads/Project_Solutions/ Expand.zip file Open solution

3 Add Button to Home Form Enter New Order will be enabled only when a customer is selected. Brings up new Order Entry form. btnEnterOrder

4 Add Order Entry Form

5 Order Entry Form Double click on form to create Form Load event handler. lblCurrentCustomer

6 Order Entry Form private void Order_Entry_Form_Load(object sender, EventArgs e) { lblCurrentCustomer.Text = "Order for customer: " + Program.Selected_Customer.CompanyName; }

7 Enter New Order Add code to Home form to show Order_Entry_Form. private void btnEnterOrder_Click(object sender, EventArgs e) { Order_Entry_Form f = new Order_Entry_Form (); this.Hide(); f.ShowDialog(); this.Show(); }

8 Enable Order Entry In Home Form, enable Enter Order button if, and only if, there is a selected customer.

9 Home_Form.cs private void btnSelectCustomer_Click(object sender, EventArgs e) { Select_Customer_Form sc = new Select_Customer_Form(); this.Hide(); sc.ShowDialog(); this.Show(); btnEnterOrder.Enabled = Program.Customer_Selected; if (Program.Customer_Selected) { Customer c = Program.Selected_Customer; tbSelectedCustomer.Text = c.CompanyName; } else { tbSelectedCustomer.Text = "No Customer Selected"; } Build and run.

10 Order Entry Form

11 Order Entry Form User will specify Product Category. Product Quantity Click Submit or Cancel

12 Specifying the Product Use a data bound Dropdown list on the Order Entry form to select Product Category. Add and configure data source. Data > Add New Data Source Table Categories Display: CategoryName Value: CategoryID

13 Add New Data Source

14 New Data Source

15 Specify Connection Click New Connection

16 Add New Connection Click OK

17 Configuring the Data Source Click Next

18 Configuring the Data Source Click Next

19 Configuring the Data Source Click Finish

20 Binding the Data Source We have the data source. Now add a dropdown list (ComboBox) cbCategory Bind it to the data source. Details on following slides.

21 Add ComboBox cbCategory Set DataSource

22 Set DisplayMember and ValueMember

23 Set Connection String Set the connection string for the new Data Source. private void Order_Entry_Form_Load(object sender, EventArgs e) { this.categoriesTableAdapter.Connection.ConnectionString = "server=scorpius.eng.usf.edu; " + "User=" + Program.Username + "; " + "Password=" + Program.Password; // TODO: This line of code loads data into the 'dataSet3.Categories' // table. You can move, or remove it, as needed. this.categoriesTableAdapter.Fill(this.dataSet3.Categories); lblCurrentCustomer.Text = "Order for customer: " + Program.Selected_Customer.CompanyName; }

24 Add Event Handler Add an event handler for Selected Index Changed in the Categories ComboBox. Double click on the ComboBox. private void cbCategory_SelectedIndexChanged(object sender, EventArgs e) { MessageBox.Show(cbCategory.SelectedValue.ToString()); }

25 Program in Action

26 Product Selection Now add a Dropdown List that offers just products of the selected category. Drag ComboBox from Toolbox. Dont copy and paste the first ComboBox. New ComboBox: cbProducts New Data Source: Table Products ProductID ProductName

27 Product Selection

28 Add Query for Products Note productsTableAdapter Responsible for filling DataSet Click on cbProducts to select it. Click on smart tag (upper right corner) and select Add Query Will specify the query that will be used by the productsTableAdapter to fill the data set that is bound to the Products ComboBox.

29 Smart Tag Clicked Click Add Query

30 New Query

31 Set Connection String private void Order_Entry_Form_Load(object sender, EventArgs e) { // TODO: This line of code loads data into the... this.productsTableAdapter.Connection.ConnectionString = "server=scorpius.eng.usf.edu; " + "User=" + Program.Username + "; " + "Password=" + Program.Password; this.productsTableAdapter.Fill(this.productsDataSet.Products); this.categoriesTableAdapter.Connection.ConnectionString = "server=scorpius.eng.usf.edu; " + "User=" + Program.Username + "; " + "Password=" + Program.Password; this.categoriesTableAdapter.Fill(this.dataSet3.Categories); lblCurrentCustomer.Text = "Order for customer: " + Program.Selected_Customer.CompanyName; }

32 Update cbCategory Event Handler private void cbCategory_SelectedIndexChanged(object sender, EventArgs e) { //MessageBox.Show(cbCategory.SelectedValue.ToString()); int category_id = (int)cbCategory.SelectedValue; this.productsTableAdapter.FillByCategory(this.productsDataSet.Products, category_id); cbProducts.Enabled = true; } Whenever a new category is selected, the Products table in ProductsDataSet will be refilled using the FillByCategory query.

33 Program in Action

34 Clean Up the Form We dont need the fillByCategoryToolStrip Right click, Delete

35 Delete Event Handler Delete event handler for fillbyCategoryToolStripButton //private void fillByCategoryToolStripButton_Click(object sender // EventArgs e) //{ // try // { //... // } // catch (System.Exception ex) // { // System.Windows.Forms.MessageBox.Show(ex.Message); // }

36 Program in Action

37 Add Event Handler Double click on cbProduct to add an event handler. private void cbProduct_SelectedIndexChanged(object sender, EventArgs e) { MessageBox.Show(cbProducts.Text); }

38 Program in Action