home *** CD-ROM | disk | FTP | other *** search
- //--------------------------------------------------------------
- //
- // Mugs.cfm -- Custom form classes for the Mugs application.
- //
- // The mugsCForm defines a default color for forms in
- // the Mugs application.
- //
- // The mugsDataCForm is a template for data entry
- // forms in the Mugs application. It includes
- // definitions for a color, title, notebook
- // and grid. It also contains methods for resizing
- // controls on the data entry forms.
- //
- // Dependencies: <none>
- //
- // Visual dBASE Samples Group
- //
- // $Revision: 1.11 $
- //
- // Copyright (c) 1997, Borland International, Inc.
- // All rights reserved.
- //
- //---------------------------------------------------------------
-
-
- CLASS mugsCForm OF FORM custom
- this.ColorNormal = "burlywood"
- this.Height = 18.4118
- this.Left = 23
- this.Top = 4.0588
- this.Width = 56
- this.Text = ""
-
-
- ENDCLASS
- class mugsDataCForm of FORM custom
- with (this)
- canClose = class::FORM_CANCLOSE
- onSize = class::FORM_ONSIZE
- Open = class::FORM_OPEN
- scaleFontSize = 8
- scaleFontBold = false
- colorNormal = "APPWORKSPACE"
- height = 15
- left = 10
- top = 2
- width = 56.8333
- text = ""
- endwith
-
-
- this.TITLE = new TEXT(this)
- with (this.TITLE)
- height = 1.5
- left = 1
- top = 0.5
- width = 54
- border = true
- metric = 0
- colorNormal = "MenuText/Menu"
- alignVertical = 1
- alignHorizontal = 1
- fontSize = 8
- text = "<h2>title</h2>"
- borderStyle = 2
- endwith
-
-
- this.BOOK1 = new NOTEBOOK(this)
- with (this.BOOK1)
- height = 12
- left = 1
- top = 2.5
- width = 54
- metric = 0
- fontName = "MS Sans Serif"
- fontSize = 8
- dataSource = 'ARRAY {"Row","Table"}'
- borderStyle = 2
- endwith
-
-
- this.BOOK1.GRIDROWS = new GRID(this.BOOK1)
- with (this.BOOK1.GRIDROWS)
- bgColor = "white"
- pageno = 2
- height = 10.3529
- left = 0.5
- top = 1.5
- width = 52
- metric = 0
- endwith
-
- // {Linked Method} Form.onSize
- function Form_onSize(nSizeType, nWidth, nHeight)
- this.TITLE.width := ( nWidth - 2 )
- this.book1.move( this.book1.left, ;
- this.book1.top, ;
- ( nWidth - 2 ),;
- ( nHeight - 3 ) )
- this.book1.gridRows.move( this.book1.gridRows.left, ;
- this.book1.gridRows.top, ;
- ( nWidth - 4 ), ;
- ( nHeight - 5 ) )
- return ( nSizeType )
-
- // {Linked Method} Form.open
- function Form_open
- class::Form_OnSize( 0, this.width, this.height )
- return SUPER::OPEN()
-
- // {Linked Method} Form.canClose
- function Form_canClose
- if ( TYPE('this.rowset.state') == "N" )
- if ( this.rowset.state == 3 )
- this.rowset.abandon()
- endif
- endif
- return true
-
- endclass
-