|
|
 |
 |
To access the contents, click the chapter and section titles.
Visual Basic 6 Black Book
(Publisher: The Coriolis Group)
Author(s): Steven Holzner
ISBN: 1576102831
Publication Date: 08/01/98
Chapter 30 Deploying Your Program: Creating Setup Programs, Help Files, And Online Registration
- If you need an immediate solution to:
- Creating Your Applications EXE File
- Using The Package And Deployment Wizard
- Step 1: Package Type
- Step 2: Build Folder
- Step 3: Files
- Step 4: Distribution Type
- Step 5: Installation Title
- Step 6: Icons
- Step 7: Install Locations
- Step 8: Shared Files
- Step 9: Finished!
- Creating Help Files With The Microsoft Help Workshop
- Creating A Help Projects RTF File
- Entering Text In A Help File
- Creating A Help Hotspot
- Creating A Help Hotspot Target
- Titling A Help Page
- Adding Help Topics To The Help Index
- Creating Help Pop-Up Links
- Creating Help Tool Tips Targets
- Compiling Help Files With The Help Workshop
- Displaying A Help File From Visual Basic
- Building Online Help Into Your Application
- Creating Online User Registration
- Uploading Online Registration Information To An FTP Server
- Concluding The FTP Transfer Of The Online Registration Information
In Depth
Youve created your application, and its a doozy. It runs fineon your computer. But whats next? How do you get your application out the door and onto other peoples computers?
Thats what this chapter is all about. Here, were going to reap the benefits of all our work by deploying applications to users. Well see how to create setup programs, Help files, and even online registration.
Application deployment is a topic many books skip, but its of vital interest to many programmers. After all, the EXE files you create might run fine on your computer, which has a full installation of Visual Basic on it, but what about other computers? You cant just copy the EXE files to another computer and expect them to run: Visual Basic applications require a great deal of support in terms of dynamic link libraries and possibly other components like ActiveX controls you may have used. How do you install all that? Well see how that works in this chapter.
Setup Programs
You use setup programs to install your application on other computers, and Visual Basic has a good tool that will help us here: the Package And Deployment Wizard. Using this wizard, you can create setup files that you can distribute on CDs, multiple disks, or even across the Internet.
TIP: Its important to make sure that you dont distribute licensed material or components without permission, of course. Check with the manufacturer of the DLL or OCX files you want to distribute first, making sure its policy allows distribution.
In this chapter, well see how easy it is to create setup programs with the Package And Deployment Wizard. Once youve created your applications EXE file, youre all setthe Package And Deployment Wizard will analyze what files your application needs and include them in the data file for your setup program. The data itself is stored in a cabinet file, with the extension .cab, and the setup.exe program will unpack and deploy the contents of that file as needed.
Help Files
Help files are an asset to any application, and just about all serious applications come with a Help system of some sort. In this chapter, well see how to create Windows Help files of the kind you can display on the users computer with standard Windows calls.
To create a Windows Help file, you use the Windows Help Workshop, which creates a Help project. You place the actual Help text in a rich text (RTF) file, and add that file to the Help project. Why rich text? The Help Workshop uses RTF files so that you can embed jumps, called hotspots, that work like hyperlinks, and commands directly into your Help file, encoding those items with rich text footnotes, hidden text, and so forth. Well see how this works in this chapter. When youre done with your RTF file, you use the Help Workshop to compile it into an HLP file.
Now that you have an HLP file, how do you open it from Visual Basic? Here, well use the Windows API WinHelp function, which allows you a great deal of flexibility when opening Help files. You can even make the Package And Deployment Wizard include your Help files and data files in the setup program, as well see in this chapter.
Online Registration
Keeping in touch with an applications users is important for many programmers, which is why online registration has become so popular. Using online registration, the user has only to select a menu item to register the application with you.
In this chapter, well use the FTP protocol to let users connect and register their applications in a few easy steps. Using FTP is probably the most common method for handling online registration and provides us with a better and more robust alternative to using another alternative, email, because the Visual Basic email support relies on the Microsoft MAPI system, which the user may not have enabled.
When users decide to register online, the program will display an information dialog box, asking them to enter their name and email address. When they click a button labeled Register, the program will establish an FTP connection to your server (connecting to the Internet, if necessary, first) and upload the information the users provided, along with the date and time. In this way, you can keep track of your applications users.
|