Energizing Your Programs With Active. X l What is Active. X l What will it do for me l How can I use it
What is Active. X l It is a tried-and-tested control l Progressbar l Multi-object Calendar l Web. Browser l Interact with it l Call Functions and Procedures l Set Properties l Receive Events l Can be Visual or non-visual l Html-Label l Spell Checker
What Will It Do For Me l Enable you to add powerful or visual features immediately and cheaply l Add capabilities otherwise unavailable l Save development time l How long would it take to write a spellchecker or graphics utility? l Now multiply that by five
How Can I Use It l Obtain the controls l Import them in the IDE l Drag them from the Controls Palette
Obtaining Active. X Controls l Built-in l Imaging, Animation, Video, etc l Buy l Magazines such as Visual Developer, etc l Download from www. Active. X. com, etc
Import Into The IDE l Two parts l The easy, fun, visual side l The difficult, complex, error-prone, timeconsuming never-gonna-get-it-all-working side
Import Into The IDE The easy part l You Do: l Select from Registered Controls l Global or Workspace l Simple or Data-Aware
Import Into The IDE The not-easy part l The IDE Does: l Create the PKG Class-File l Creates the DFC file l Creates the DFO l Creates the bitmap (both) l Registers in the Class-List l Puts on Controls Palette
Dragging From The Controls Palette l Property Page l Property. File/. OCP l On. Create l Com/On. Com prefixes
What We’re Going To Do Next Create several Simple Active. X Controls Create two Data-Aware Active. X Controls Show Property Pages Show using the On. Create event to set the Active. X properties l Using regular controls to interact with the Active. X controls l l
And For Free l Learn the common mistakes l Learn how to use the new Code Explorer and Error Reconciliation to fix bugs
Simple Active. X Controls l Instance of the c. Com. Control l l l c. Html. Label c. Folder. Picker c. Rich. Text. Box c. Cool. Progress. Bar c. Analog. Clock c. Spell. Checker c. Simple. Printer
Data-Aware Active. X Controls l Instance of the c. Db. Com. Control l Need to provide two events l On. Refresh. Db. Ocx. Value (DD->DEO) l ? ? ? (DEO->DD) l (//To. Do: Ctrl+T) l c. Db. Date. Picker l c. Db. Bitmap
c. Db. Date. Picker l Provide a popup calendar for Date fields l Import as Global l Import from Windows Common Controls-2 l Data-Events l On. Refresh. Db. Ocx. Value (DD->DEO) l On. Com. Change (DEO->DD)
c. Db. Bitmap l Replacement for the db. Bitmap class to show JPG/BMP/GIF, etc l Import from built-in Kodak Image Edit l Set it as the Visual Control in DBB l Implement Zoom feature with Trackbar l Data-Events l On. Refresh. Db. Ocx. Value (DD->DEO) l Relative vs Absolute pathing l Displaying l Clearing
Where Next l Run the COM sample Workspace l Read the Help l Importing Active. X Controls (IDE) l Outlines the process and has a tutorial l COM Class Reference l Close Power. Point and do it!