Chapter 4. Developing a Windows Application

Now that you've become familiar with the latest features of the VB 2005 language and the new productivity tools added to Visual Studio 2005, it's time to build a complete application.

In this chapter, you will build a Windows application that you can use to create an online catalog of the books you own. The catalog stores details such as the ISBN (the book industry standard number used to uniquely identify a book), title, authors, publisher, and price of each volume in your collection. The application lets you search for information about particular titles by entering keywords in a search window. You can then store that information, including images of the book covers, in a personal database on your Windows workstation or PC.

Later in the chapter, you'll add a second window to the application that lets users display the complete catalog of books stored in the local database and to display the details of any particular title.

Figure 4-1 shows the main window of the finished application. The window includes two panels: a panel on the left for showing the results of keyword searches that you enter and a panel on the right for displaying the details of a particular book returned by the search. The main window contains the usual features you expect to find in a Windows application such as a menu, a toolbar, and a status bar. Figure 4-30 shows the finished application with both windows open.

You will build the application using several of the latest Visual Studio 2005 controls, including the SplitContainer, MenuStrip, ToolStrip, and StatusStrip controls. You will also work with data access controls and wizards that simplify the use of the ADO.NET classes for data access. You will use the web service to retrieve detailed information about your books and then save it for offline viewing, and you'll see how easy it is to incorporate a web service in an application with Visual Studio 2005. Though multithreading has traditionally been seen as a black art, the new BackgroundWorker control reduces its use to a drag-and-drop operation. You'll use multithreading to keep the UI of your Windows application responsive while it's accessing the web service.

Once the library application is complete, you will use ClickOnce, a new smart client deployment technique in the .NET Framework 2.0, to post it to an IIS host. ClickOnce is not only an easier way to deploy Windows applications that make use of the Internet, but ClickOnce also ensures that the user will be notified whenever an updated version of the application is posted to the server. You'll use this feature to deploy an updated version of the library application at the end of this chapter.

Figure 4-1. The completed personal library application

Visual Basic 2005 Jumpstart 2005
Visual Basic 2005 Jumpstart
ISBN: 059610071X
EAN: 2147483647
Year: 2005
Pages: 86
Authors: Wei-Meng Lee

Similar book on Amazon © 2008-2017.
If you may any questions please contact us: