User Interface

only for RuBoard - do not distribute or recompile

User Interface

The user interface will consist of an initial form to display when the user launches the application: frm_reports. From there, each of the other separate reports is launched.

Login Screen ”frm_reports.

This form will be the control point for all the reports available in this application. Figure 11.1 shows the UI design.

Figure 11.1. frm_reports ”the main control of the application.
graphics/11fig01.gif

Figure 11.1 is the window that will initially come up for the user. He or she will pick one of the available reports and click Open to view the report in its own window. Each report will be its own executable stored on the local machine in order to add new reports without having to recompile everything in this project. Also, the list of available reports will be kept in a table so that when new reports come online, a new line will be added and the KBI application will automatically bring it up.

Report 1: Tabular Report ”Salesperson Ranking

This one shouldn t be too tough. In fact, the data display control from the Worldwide Commissions project can be modified slightly for use here. See Figure 11.2 for an example.

Figure 11.2. Tabular report example.
graphics/11fig02.gif

Remember that the window shown in Figure 11.2 will be running in its own process space.When opened, the software will do the following:

 drop table tbl_top_salespeople;  create table tbl_top_salespeople       select distinct last-name & salesperson as salesperson,              /* (to sort and view by name not just number) */              sum(commission) as commission,              count(*) as row_count       from tbl_commissions       group by salesperson;  select * from tbl_top_salespeople order by commission DESC; 

Then the software will create the tabular display using the data display control from Chapters 8 and 9 (modified for this project). It will be a simple display, sorted down by the sum of commissions paid by salesperson.

Report 2: Pie Chart ”Sales by Division

This report will show you how to build a pie chart from a dataset.The data will show sales by division (the data is in Listing 11.2).

The following are the five divisions for the Sales by Division report:

  • Widgets

  • Components

  • Connections

  • Peripherals

  • Hardware

The report will show data for the most recently completed month. In other words, the software will find out the current month by getting the current date, and then it will retrieve the data for the previous month. Also, the definition of this report is to show sales by division; if a new division appears in the data, the software should take that into account and produce a chart with six pie slices instead of five. Figure 11.3 shows an example report; note that in the final on-screen version, the pie wedges will be color -coded with matching colors in the Legend.

Figure 11.3. Pie chart report example.
graphics/11fig03.gif
Report 3: Bar Chart ”Year-to-Date Sales Trend Versus Quota

This report will show sales year-to-date as a bar chart with the months running along the horizontal axis and the numbers along the vertical. Overlayed on that bar chart will be a line showing the sales goal or quota. By definition, this report will always show 12 calendar months, so it can make the assumption that the horizontal will always show 12 values. Figure 11.4 shows the desired result.

Figure 11.4. In the example bar chart, the bars represent sales for the current year, and the line shows the sales goal.
graphics/11fig04.gif

Report 4: Scatter Plot ”Finding Correlations in Numeric Data

This view will allow the user to plot any two numeric columns from tbl_revenue; this will allow the user to identify data points that fall outside the norm. The norm will usually be a bisecting line of data points from the lower-left corner to the upper-right corner, as shown in Figure 11.5. There are several candidate columns to choose from:

Figure 11.5. Correlating two numeric variables :Who is data point (line number) 55, and why is he out there all by himself?
graphics/11fig05.gif
  • order_quantity

  • unit_price

  • net_value

  • invoice_quantity

  • invioce_value

The numbers in parentheses show the line number of the data point. This is to allow the user to identify a line for further analysis (which would make a good follow-up for this graph; after all, what s the use if the user can t investigate further?).

only for RuBoard - do not distribute or recompile


MySQL Building User Interfaces
MySQL: Building User Interfaces (Landmark)
ISBN: 073571049X
EAN: 2147483647
Year: 2001
Pages: 119

flylib.com © 2008-2017.
If you may any questions please contact us: flylib@qtcs.net