APL+Win Training Pack 13

Formula One OCX Tutorial & MDI Revisited with OOP

Download APL+Win Training Pack 13 (2132 K)

The WinWord document in this Pack has been split into 2 files: DISK131.DOC and DISK132.DOC.  You may print both of them and then group the printouts into one bound document.

Formula One OCX Tutorial

Although we have already talked a lot about Formula One OCX in this APL+Win Training Program, we have decided to include a basic Formula One OCX Tutorial, to show how to use a good number of Formula One OCX properties and methods.

The FONE.W3 workspace includes a number of utility functions which you will find useful for:

  • printing data from APL+Win without displaying any form
  • publishing APL+Win arrays to the Web
  • retrieving data from ODBC databases without displaying any form
  • importing EXCEL worksheets to APL+Win Nested Arrays without displaying any form
  • efficiently populating the Formula One grid with APL data
  • efficiently retrieving the Formula One grid content to an APL Nested Array

You will certainly like the ClipFmt and ClipUnfmt utilities which offer the ultimate performance in writing and reading APL data to/from the Formula One OCX spreadsheet.

MDI Revisited with OOP

The 25th Chapter of our APL+Win Training revisits the topic of writing MDI (Multiple Document Interface) applications, this time with only using objects and OOP technology.

The WINSOFT.W3 workspace contains a significant number of completely reusable objects which you may use for developing your own MDI applications.

Chapter 25 shows how using pure OOP technology in APL+Win is not just theory, but a real practical, efficient and clean way of developing applications.

Just to give you a taste of it here is a screen shot of an MDI application written with our collection of new User Defined objects and here is below the whole APL+Win code required to write this application:

Here is the APL+Win OOP code which produces this fully functioning MDI application with complete menus:

    ∇ Test;Z;⎕wself
[1]   ⍝ Sample OOP MDI Application
[2]   ⍝ Copyright (c) 1997 Eric Lescasse
[3]   ⎕wself←'ff'Qwi'New' 'MDIForm'('caption' 'OOP MDI Application')
[4]       Qwi('inifile' 'winsoft.ini')('bitmap' 'c:\windows\nuages.bmp')
[5]   ⎕wself←'ff.mFile'Qwi'New' 'FileMenu'
[6]       Z←'New' '-' 'Open' 'Close' 'Delete' '-' 'Save' 'SaveAs' '-'
[7]       Z←Z,'PrintSetup' 'PrintPreview' 'Print' 'MRU' '-' 'Exit'
[8]       Qwi'options' Z
[9]   ⍝   Qwi'childtype' 'ChildRegForm'
[10]  ⎕wself←'ff.mView'Qwi'New' 'ViewMenu'
[11]      Z←Qwi'options' 'ToolBar' '-' 'StatusBar'
[12]  ⎕wself←'ff.mWin'Qwi'New' 'WinMenu'
[13]      Qwi'options' 'Cascade' 'TileH' 'TileV' 'Arrange' '-' 'Close'  'Iconify'
[14]  ⎕wself←'ff.mHelp'Qwi'New' 'HelpMenu'('options' 'Help' '-' 'About')
[15]      Z←'Sample APL+Win application using OOP technology'
[16]      Z←Z,⎕tcnl,'Copyright ⍝ 1997 Eric Lescasse'
[17]      Qwi'abouttext' Z
[18]      Qwi'abouticon' 'aplwin.ico'
[19]      Qwi'abouttitle' 'APL2000 User''s Conference'
[20]      Qwi'helpfile' 'winsoft.hlp'
[21]  ⎕wself←'ff.fTb1'Qwi'New' 'MDIToolBar'
[22]      Qwi'buttons'1 2 3 18 0 4 9 10 0 5 6 7 11 12 0 27 28 0 83 104
[23]  ⎕wself←'ff.fTb2'Qwi'New' 'MDIToolBar'
[24]      Qwi'buttons'1001 0 1002 0 22 29 45 0 31 25 34 0 36 37
[25]  'ff'Qwi'ShowMax'

Finally Chapter 25 introduces a useful Object Oriented technique which helps make APL+Win having complex forms with high interactions between form controls much easier to write and to maintain.

This OOP technique involves having your control objects send messages to other control objects to instruct them to update themselves.

Pack 13 Content

File Description
BUTTONS.BMP More than 100 images for your toolbar buttons.
DISK131.DOC An 40 pages Winword document containing Chapter 24 of the APL+Win Training.
DISK132.DOC An 38 pages Winword document containing Chapter 25 of the APL+Win Training.
FONE.W3 Formula One OCX utilities and tutorial
WINSOFT.W3 A collection of reusable objects for developing MDI applications
WINSOFT.HLP A sample small Help file for the MDI application
WINSOFT.INI The WINSOFT application .INI file.