Visual FoxPro Training Overview
Learning a complex tool like Visual FoxPro requires a foundation of knowledge about
data and how Visual FoxPro handles it.
The foundation for VFP begins with the data, container and fields associated with it.
Database output (queries) explains FP tables, fields, and cursors as read-only data. We
should spend some time on queries, perhaps as we complete data.
Outer joins (all customers and invoice data where there are invoices) were added in VFP
5.0. We need to look at the different ways of relating tables: with SQL Join and the
language based SET RELATION TO.
While VFP 6.0, with SP 5 has been very solid, the Fox team has been busy
building versions 7, 8 and 9. Each have small updates, including improved
interoperability with other OLE and now .NET. There were small memory
leaks that are now fixed. We noticed one in the OLEDB engine that was fixed
in VFP 8 SP 1.
The training The topics and skill development are not developed in a strictly sequential manner, in
fact we hope that folks have all sorts of knowledge and skills that let them speed through
this material and be productive the moment they apply themselves.
Delivery and Topics
Currently, I am conducting Visual FoxPro Developer training using this set of topics as
the objectives, the latest in Visual FoxPro texts available as the study, and the goals of
the students. I distribute or discuss the topics prior to the class, provide the topics
list at the beginning of the first day, and check in with the students at every break
during the course. Some programmers want to make sure we cover the broadest possible set
to topics; others want to practice as much as possible. Some learn best watching the
process based on a demonstration. I lecture, we explore examples from the texts and
Microsoft sample files and we develop forms and classes also.
Training Manuals
It would be nice to use custom training manuals for these classes, but I haven't had
the revenue from VFP training to justify the 875 hours it would take to finish the manuals
based upon the outline I started in 1995. I have used other manuals (including the
Microsoft Press material and another local brand) for training, but find that the books
available from the bookstores serve as much better texts for reference material after the
class. I use the white board and VFP itself to help explain the process as we work in
class.
Visual FoxPro Basics 2 day course
It's an intro course, for non-programmers. I've taught it only once. The material
should be mastered by programmers, so I include the topics in the VFP Application
Development 1. I cover quickly the material about tables and databases, then move on to
queries, views, and reports. Unlike some, I don't believe the wizard developed forms are
useful unless you add programming, so I don't use them. In other words, if you are not
ready to use programming techniques, go to Microsoft Access - it has a fast learning curve
that you can do more without programming. The queries and report topics are listed here.
- Queries
- SQL vs. Other...
- Updateable
- Language vs. Tools
- Queries as program
- Retrieving Data Advanced
- Unions
- Report Processing
- Bands
- Advanced concepts
- Report Variables
- Report Data - Pass 2
- Data grouping
- Sums AVG, calc fields, report variables
- partial sums, IIF()
- Memo field, stretch, float
- Two pass report calculation. E.g., percentage of the group total.
Foundations: Topics for Programmers -
Databases, Tables and Relationships
These topics must be known - I cover them quickly if requested, otherwise integrate
them in with the other material... The importance of the database container becomes
evident only later - I just fixed a problem at one remote site by taking tables
"out" of a database container. There was nothing wrong we could see, but the
users at one site were having data problems when others with "identical" data
structure and application.
- Database & Tables
- Database Containers
- Attached vs. Free
- Format
- Creating tables
- Field names, types, etc
- Types of Visual FoxPro Data
- Measurement (numeric, float, integer, date, time)
- Descriptive, short (name, city, etc.)
- Descriptive, long (memo, paragraphs...)
- OLE (graphics, video, sound, binary)
- Names, long & short
- Indexes as Keys
- Primary Key, Candidate
- Foreign key (Reference to additional table)
- Regular indexes
- Creating Relationships
- Persistent vs. Normal
- Data validation / Foreign key relationship
- Normalization issues
- Normal Form
- Denormalization Optimization for Speed
- Buffering, Saving Changes
- Buffering as a way of processing data for many users
- Buffering Table vs. Record
- Optimistic Buffering
- Pessimistic Buffering
- Commit, Rollback
- FP 2.x methods
- Stored Procedures (First Pass)
- Rules
- Triggers
Foundations: Topics for Programmers -
Visual FoxPro Language
VFP's language is based on FoxPro, then all the way back to dBase and the other
"XBase" languages of Clipper and WordTech (which has been folded into Visual
dBase). With Visual FoxPro, the language added object oriented commands and syntax, but
much of the foundation is in FoxPro 2.6. Again, I perform enough of an introduction to
save the new programmers time later, and move on. Some aspects are really different from
VB and C like variable scoping, parameter passing and the private declaration.
- Language Introduction
- Xbase (classic FP 2.x & before)
- categories of commands
- Other issues
- Deadlock
- Reuse deleted records
- Goleys deleted record/primary key note
- Pack, reindex issues
- Memory variables
- MEMVAR discussion
- Scatter, gather
- Scope - delayed until after procedure / function
- Arrays
- Creating, []vs. ()
- Redimensioning, single vs. multi dimensional
- Dimension 2 to 1
- Re-Size without loosing data, etc
- Language Details
- Writing Programs
- Commands, command rules, getting help about commands
- Program control
- Conditional execution
- Looping
- Processing data
- Procedures & functions
- Passing Parameters
- Variable declaration
- Local
- Private
- Variable scope
- Data manipulation commands
Visual FoxPro Application Development 1:
Projects, Forms and Controls
- Rapid Application Development: Introduction to Forms and the Visual Object Model
- Building Objects: Overview
- Polymorphism,
- Inheritance
- Encapsulation.
- Preparation: Objects as classes... We will come back to these
- First pass: objects with properties, events & methods
- Base Classes
- Base objects as building blocks
- Use form and form controls as exams
- A Simple Form
- Single table, no real lookup or subform
- Nothing but the Data events!
- Worry about the IDE - VFP Integrated Development Environment
- Demo
- Practice
- Exercise here!
- VCR Controls
- Standard Menu (without mods)
- Single table
- Projects
- Put the code in one place
- Control the development process
- Naming convention
- Make the form more complex
- Different types of controls
- Combo boxes
- Radio buttons, check boxes
- Worry about data
- Data validation
- Controlling tab order
- Data environment
- More and more complex forms
- Page frames
- Grids
- Other Container objects
- Other Objects on forms
- Image
- OLE: Sound,
- Form sets
- Multi table forms
- Multi Table Forms - Many to One (Lookup)
- Multi-table Forms - One to Many
- Toolbars
- Menus
- Tools in Solving Programming Problems
- Debug
- Trace
- On error processing - vs. Error method
- Data sources
- Tables
- Views - view conditions
- Data buffering, commits, MU issues, etc..
- Strategies for saving changes:
- Pessimistic, Optimist, etc.
Visual FoxPro Application Development 2: Project
Management, Classes, Subclasses and more Objects
We build upon AD1 - but really focus on the process of building applications with
classes. While I know (and do in my own VFP work) that it is quick fun to drop fully
developed objects on a form, modify a few properties, then see the working complexity
running, to do so early in the VFP learning process obscures the many details of the
different objects.
And, for fair percentage of the VFP students I have seen, navigating the complexities
of multi-classed objects is too confusing as they view early in their Visual FoxPro
experience the full cornucopia of VFP properties and methods. So, we have success in
developing forms, then turn to the complexities of working with VFP classes.
If an individual's organization has chosen any particular class library as the company
standard, I want to work with it in this class.
- Review of Object Oriented Programming Goals
- Plan and engineer for re-usability
- Develop and testing
- Use, use, use
- Return to Theory
- Polymorphism
- Inheritance
- Encapsulation
- Why do they help us??
- Subclasses, superclasses, & "classing" and object - nomenclature
- Return to VFP
- Find the pieces in the IDE (Interface)
- dodefault() command - new to VFP 5
- :: scope resolution operator
- VFP Base Classes
- List the object types
- Look at the common properties & methods
- Base class as starting over
- See notions of set century on, set deleted on etc.
- Object browser
- Custom classes - nonvisual classes
- Follow the subclassing code
- Lab examples
- Simple -form objects for font size, color etc
- Telephone, default area code, lookup etc.
- Instantiation - several forms run from menu
- Object as including the "data environment" - a classed form can't have a data
environment
- Classing the data buffering events - pick any set of classes to examine
- The application object - again, explore the application object from the class library of
your choice
- VFP sample controls - more fun to explore
Visual FoxPro Application Development 3:
Advanced Use of Data, OLE Objects and Remote Data
I want to teach this class as a full set of topics, but haven't - folks haven't needed
these topics to be productive. I have performed quick demos, u
Lessons and tasks we have performed in class include:
Mailmerge with Word
Report with Word
OLE & Outline Tool
OLE & Pivot Table Control
OLE & MS Graph
OLE & Pinnacles Graphics Server
Excel via OLE
Client Server topics - Now in 1998, perhaps we should use Visual InterDev, rather than
Visual FoxPro.
Strategies for Client Server
Moving to Client Server - Upsizing a database
Triggers
Server side programming
SQL Server Administration
Questions? - email me, craig {{a-t}} c0mputer-u.c0m |