home *** CD-ROM | disk | FTP | other *** search
/ DP Tool Club 24 / CD_ASCQ_24_0995.iso / win / prg / vbstra / demoapp / strdllap.frm < prev    next >
Text File  |  1995-06-23  |  19KB  |  726 lines

  1. VERSION 2.00
  2. Begin Form StrDLLApp 
  3.    BackColor       =   &H00C0C0C0&
  4.    Caption         =   "VBstrAPI.DLL Demonstrator"
  5.    ClientHeight    =   5985
  6.    ClientLeft      =   45
  7.    ClientTop       =   1410
  8.    ClientWidth     =   8070
  9.    Height          =   6390
  10.    Icon            =   STRDLLAP.FRX:0000
  11.    Left            =   -15
  12.    LinkTopic       =   "Form1"
  13.    ScaleHeight     =   5985
  14.    ScaleWidth      =   8070
  15.    Top             =   1065
  16.    Width           =   8190
  17.    Begin ListBox List 
  18.       BackColor       =   &H00808000&
  19.       FontBold        =   0   'False
  20.       FontItalic      =   0   'False
  21.       FontName        =   "Fixedsys"
  22.       FontSize        =   9
  23.       FontStrikethru  =   0   'False
  24.       FontUnderline   =   0   'False
  25.       Height          =   1605
  26.       Left            =   5520
  27.       TabIndex        =   8
  28.       Tag             =   "OL"
  29.       Top             =   270
  30.       Width           =   2475
  31.    End
  32.    Begin TextBox Monitor 
  33.       BackColor       =   &H00C0C0C0&
  34.       FontBold        =   0   'False
  35.       FontItalic      =   0   'False
  36.       FontName        =   "Fixedsys"
  37.       FontSize        =   9
  38.       FontStrikethru  =   0   'False
  39.       FontUnderline   =   0   'False
  40.       Height          =   675
  41.       Left            =   150
  42.       MousePointer    =   1  'Arrow
  43.       MultiLine       =   -1  'True
  44.       ScrollBars      =   3  'Both
  45.       TabIndex        =   1
  46.       Tag             =   "OL"
  47.       Top             =   1980
  48.       Width           =   5265
  49.    End
  50.    Begin PictureBox ToolBar 
  51.       BackColor       =   &H00808000&
  52.       Height          =   1875
  53.       Left            =   0
  54.       ScaleHeight     =   1845
  55.       ScaleWidth      =   5400
  56.       TabIndex        =   0
  57.       Tag             =   "OL"
  58.       Top             =   0
  59.       Width           =   5430
  60.       Begin PictureBox Picture1 
  61.          AutoSize        =   -1  'True
  62.          BorderStyle     =   0  'None
  63.          Height          =   1800
  64.          Left            =   2970
  65.          Picture         =   STRDLLAP.FRX:0302
  66.          ScaleHeight     =   1800
  67.          ScaleWidth      =   2400
  68.          TabIndex        =   7
  69.          Top             =   30
  70.          Width           =   2400
  71.       End
  72.       Begin SSCommand biQuit 
  73.          Caption         =   "&Exit"
  74.          Font3D          =   1  'Raised w/light shading
  75.          ForeColor       =   &H00000000&
  76.          Height          =   1800
  77.          Left            =   2250
  78.          Picture         =   STRDLLAP.FRX:28FC
  79.          RoundedCorners  =   0   'False
  80.          TabIndex        =   6
  81.          Top             =   30
  82.          Width           =   705
  83.       End
  84.       Begin SSCommand biArray 
  85.          Caption         =   "&ArrayStr"
  86.          Font3D          =   1  'Raised w/light shading
  87.          Height          =   900
  88.          Left            =   1140
  89.          Picture         =   STRDLLAP.FRX:2B66
  90.          RoundedCorners  =   0   'False
  91.          TabIndex        =   5
  92.          Top             =   930
  93.          Width           =   1095
  94.       End
  95.       Begin SSCommand biCat 
  96.          Caption         =   "&CatStr"
  97.          Font3D          =   1  'Raised w/light shading
  98.          Height          =   900
  99.          Left            =   30
  100.          Picture         =   STRDLLAP.FRX:2E68
  101.          RoundedCorners  =   0   'False
  102.          TabIndex        =   4
  103.          Top             =   930
  104.          Width           =   1095
  105.       End
  106.       Begin SSCommand biCopy 
  107.          Caption         =   "C&opyFile"
  108.          Font3D          =   1  'Raised w/light shading
  109.          Height          =   885
  110.          Left            =   1140
  111.          Picture         =   STRDLLAP.FRX:316A
  112.          RoundedCorners  =   0   'False
  113.          TabIndex        =   3
  114.          Top             =   30
  115.          Width           =   1095
  116.       End
  117.       Begin SSCommand biFind 
  118.          Caption         =   "&FindString"
  119.          Font3D          =   1  'Raised w/light shading
  120.          Height          =   885
  121.          Left            =   30
  122.          Picture         =   STRDLLAP.FRX:346C
  123.          RoundedCorners  =   0   'False
  124.          TabIndex        =   2
  125.          Tag             =   "OL"
  126.          Top             =   30
  127.          Width           =   1095
  128.       End
  129.    End
  130.    Begin Label Label1 
  131.       AutoSize        =   -1  'True
  132.       BackColor       =   &H00C0C0C0&
  133.       BackStyle       =   0  'Transparent
  134.       Caption         =   "ArrayStr Demonstration List Box"
  135.       ForeColor       =   &H00800000&
  136.       Height          =   195
  137.       Left            =   5520
  138.       TabIndex        =   9
  139.       Top             =   30
  140.       Width           =   2700
  141.    End
  142. End
  143. Option Explicit
  144.  
  145. Sub ArrayExample ()
  146. '
  147. ' Demonstration example of ArrayStr usage
  148. '
  149.  Dim SHandle As Integer ' ArrayStr object handle
  150.  Dim ii      As Long    ' iterator
  151.  Dim rc      As Long    ' return code
  152.  
  153.     ' create the sample array string
  154.  
  155.     SHandle = CreateNewStringArray(1, 1024)
  156.  
  157.     '
  158.     ' If successful, then away we go
  159.     '
  160.     
  161.     If SHandle > -1 Then
  162.  
  163.         
  164.         '
  165.         '  We'll start by filling the ArrayStr in Serial Mode
  166.         '
  167.         For ii = 0 To 9
  168.  
  169.             ' put the string NEXT in the list
  170.  
  171.             rc = PutArrayNext(SHandle, " Originally at line " & ii + 1)
  172.  
  173.             If rc < 0 Then
  174.             
  175.                 MsgBox "ArrayStr Overflow! Unable to continue.", 48, "PutArrayNext Error"
  176.                 DestroyStringArray SHandle
  177.                 
  178.                 Exit Sub
  179.             
  180.             End If
  181.  
  182.         Next
  183.  
  184.         ' now insert a string at index #3
  185.  
  186.         rc = InsertArrayStr(SHandle, 3, "!! Inserted at line 4")
  187.         
  188.         ' now delete the last string
  189.  
  190.         rc = DeleteArrayStr(SHandle, 9)
  191.  
  192.         ' replace the entry #7 with a message using Random Access
  193.  
  194.         rc = PutArrayStr(SHandle, 7, "!! Changed line 8 with PutArrayStr")
  195.  
  196.         ' place a note in the last entry that it was deleted
  197.  
  198.         rc = PutArrayStr(SHandle, 9, "!! Entry deleted by DeleteArrayStr")
  199.  
  200.         ' reset the current line pointer to the first entry
  201.  
  202.         ArrayStrSetCLP SHandle, 0
  203.  
  204.  
  205.         ' using Serial Mode, fill the demonstration list box
  206.  
  207.         List.Visible = False
  208.         For ii = 1 To 10
  209.  
  210.             List.AddItem Format$(ii, "00") & GetArrayNext(SHandle)
  211.  
  212.         Next
  213.         List.Visible = True
  214.  
  215.         'rc = ArrayStrResize(SHandle, 20)
  216.         'MsgBox "(" & rc & ") " & GetArrayStr(SHandle, 1) & " [" & ArrayStrElements(SHandle) & "]"
  217.  
  218.  
  219.         ' ALWAYS REMEMBER TO DESTROY THE ARRAYSTR WHEN FINISHED
  220.  
  221.         DestroyStringArray SHandle
  222.  
  223.     Else
  224.  
  225.         MsgBox "Not enough memory to create the ArrayStr Object!", 48, "ArrayStr Create Error"
  226.  
  227.     End If
  228.  
  229. End Sub
  230.  
  231. Sub biArray_Click ()
  232. Dim CHandle As Integer
  233. Dim rc As Integer
  234.  
  235.     ' This call is used to display the demonstration
  236.     ' code for the program.  Please don't look behind
  237.     ' that curtain. (The Wizard of OZ)
  238.     
  239.     LocateCode "Sub Array" & "Example", "End Sub" & Chr$(13)
  240.     
  241.     ArrayExample
  242.  
  243.     CHandle = CreateNewCatString(4096)
  244.  
  245.     rc = CatStrAddLine(CHandle, "Examine the Code in the Code Window below.")
  246.     rc = CatStrAddLine(CHandle, "")
  247.     rc = CatStrAddLine(CHandle, "Then examine the contents of the ListBox.")
  248.     rc = CatStrAddLine(CHandle, "")
  249.     rc = CatStrAddLine(CHandle, "The ListBox demonstrates the result of the example code.")
  250.  
  251.     HintMsg CHandle, "ArrayStr Example Code"
  252.  
  253.     DestroyCatString CHandle
  254.  
  255. End Sub
  256.  
  257. Sub biCat_Click ()
  258.  Dim rc      As Integer
  259.  Dim CHandle As Integer
  260.  
  261.     ' This call is used to display the demonstration
  262.     ' code for the program.  Please don't look behind
  263.     ' that curtain. (The Wizard of OZ)
  264.     
  265.     On Error Resume Next
  266.     
  267.     List.Clear
  268.     Kill "CatStr.Txt"
  269.     CHandle = CreateNewCatString(4096)
  270.  
  271.     Monitor = ""
  272.     LocateCode "Sub Cat" & "Example", "End Sub" & Chr$(13)
  273.  
  274.     rc = CatStrAddLine(CHandle, "What follows is a demonstration of CatStr vs VB String concatenation times for a 32k string. Only 32k strings are demonstrated because VB can not handle larger strings.")
  275.     rc = CatStrAddLine(CHandle, "")
  276.     rc = CatStrAddLine(CHandle, "When the demonstration is complete, take a look at the code below to see how it works.")
  277.  
  278.     HintMsg CHandle, "CatStr Example Code"
  279.     DoEvents
  280.  
  281.     CatExample
  282.     DestroyCatString CHandle
  283.  
  284. End Sub
  285.  
  286. '
  287. ' Note: The use of CatStrAddLine in this sub is purely
  288. '       for demonstration purposes.
  289. '
  290. Sub biCopy_Click ()
  291. Dim CHandle As Integer
  292. Dim rc As Integer
  293.  
  294.     CopyExample
  295.     
  296.     CHandle = CreateNewCatString(4096)
  297.  
  298.     rc = CatStrAddLine(CHandle, "Examine the Code in the Code Window below.")
  299.     rc = CatStrAddLine(CHandle, "")
  300.     rc = CatStrAddLine(CHandle, "The Code in the Code Window demonstrates how to use the CopyFile function.")
  301.     rc = CatStrAddLine(CHandle, "")
  302.     rc = CatStrAddLine(CHandle, "The new file is located in the same directory.")
  303.  
  304.     HintMsg CHandle, "CopyFile Example Code"
  305.  
  306.     DestroyCatString CHandle
  307.     
  308.     ' This call is used to display the demonstration
  309.     ' code for the program.  Please don't look behind
  310.     ' that curtain. (The Wizard of OZ)
  311.     
  312.     LocateCode "Sub Copy" & "Example", "End Sub" & Chr$(13)
  313.    
  314. End Sub
  315.  
  316. '
  317. ' Example use of the FindString() and CatStr Objects
  318. '
  319. Sub biFind_Click ()
  320. Dim CHandle As Integer
  321. Dim rc As Integer
  322.  
  323.     CHandle = CreateNewCatString(4096)
  324.  
  325.     rc = CatStrAddLine(CHandle, "You are about to see a demonstration of how FindString performs against InStr.  FindString works best with large strings and medium size targets (more than 3 characters).")
  326.     rc = CatStrAddLine(CHandle, "")
  327.     rc = CatStrAddLine(CHandle, "After the dialog boxes have shown you how it performs, check out the code in the code window.")
  328.     
  329.     HintMsg CHandle, "FindString vs InStr Example Code"
  330.     DoEvents
  331.  
  332.     DestroyCatString CHandle
  333.  
  334.     ' This call is used to display the demonstration
  335.     ' code for the program.  Please don't look behind
  336.     ' that curtain. (The Wizard of OZ)
  337.     
  338.     FindExample
  339.     LocateCode "Sub Find" & "Example", "End Sub" & Chr$(13)
  340.     
  341. End Sub
  342.  
  343. Sub biQuit_Click ()
  344.  
  345.     Unload Me
  346.  
  347. End Sub
  348.  
  349. '
  350. ' Demonstration of how CatStr out performs VB Strings
  351. ' in concatenation speed.
  352. '
  353. Sub CatExample ()
  354.  
  355.  Dim CHandle As Integer ' CatStr Object Handle
  356.  Dim rc      As Integer ' return code
  357.  Dim Temp    As String  ' temp string variable for save
  358.  Dim t                  ' timer accumulator
  359.  Dim VBTime
  360.  
  361.     On Error Resume Next
  362.  
  363.     ' create the maximum CatStr Object
  364.  
  365.     CHandle = CreateNewCatString(32768)
  366.  
  367.     ' Fail if not enough memory
  368.  
  369.     If CHandle < 0 Then
  370.  
  371.         MsgBox "Unable to allocate 32k for CatStr!", 48, "CatStr Create Error"
  372.         Exit Sub
  373.                 
  374.     End If
  375.  
  376.     
  377.     ' Use 'On Error Goto' to trap when string is full
  378.     '
  379.     ' NOTE: This is the fastest way to do this and simulates
  380.     '       CatStr objects more fairly than determining the
  381.     '       length of the string with Len().
  382.     
  383.  
  384. ' ****************** Visual Basic String Test ************************
  385.     
  386.     On Error GoTo VBStrFull
  387.     
  388.     Temp$ = ""
  389.     
  390.     Screen.MousePointer = 11
  391.     t = Timer
  392.     While True
  393.  
  394.         Temp$ = Temp$ & "This is a sample line of text."
  395.  
  396.     Wend
  397.  
  398. VBStrFull:
  399.  
  400.     t = Timer - t
  401.     Screen.MousePointer = 0
  402.  
  403.     On Error Resume Next
  404.     VBTime = t
  405.  
  406.     MsgBox "Concatenating a " & Len(Temp$) & " character Visual Basic String took " & Format$(t, "Standard") & " seconds."
  407.     
  408.     
  409. ' ******************** CatStr String Test ****************************
  410.     
  411.     rc = 0
  412.  
  413.     Screen.MousePointer = 11
  414.     t = Timer
  415.     While rc = 0
  416.  
  417.         rc = CatStrAddLine(CHandle, "This is a sample line of text.")
  418.  
  419.     Wend
  420.     t = Timer - t
  421.     Screen.MousePointer = 0
  422.  
  423.     MsgBox "Concatenating a " & CatStrLength(CHandle) & " character CatStr took " & Format$(t, "Standard") & " seconds."
  424.     
  425.     
  426. ' ************************* Results **********************************
  427.  
  428.     If t < VBTime Then
  429.  
  430.         MsgBox "CatStr was " & Format$(VBTime / t, "Standard") & " times faster that VB!"
  431.  
  432.     Else
  433.         
  434.         MsgBox "VB was " & Format$(t / VBTime, "Standard") & " times faster that CatStr!"
  435.     
  436.     End If
  437.  
  438.  
  439.     ' ALWAYS REMEMBER TO DESTROY THE OBJECT WHEN FINISHED!
  440.     
  441.     DestroyCatString CHandle
  442.  
  443. End Sub
  444.  
  445. Sub CenterForm (TheForm As Form, OffsetLeft As Integer, OffsetTop As Integer)
  446. Dim FLeft As Integer
  447. Dim FTop As Integer
  448.     
  449.     If TheForm.WindowState <> 0 Then Exit Sub
  450.     
  451.     FLeft = ((Screen.Width - TheForm.Width) \ 2) + OffsetLeft
  452.     FTop = (((Screen.Height - TheForm.Height) \ 2) + OffsetTop) * .85
  453.     
  454.     If TheForm.Left = FLeft And TheForm.Top = FTop Then Exit Sub
  455.     
  456.     TheForm.Move FLeft, FTop
  457.  
  458. End Sub
  459.  
  460. Sub CopyExample ()
  461. Dim rc As Integer
  462.     
  463.     rc = CopyFile("STRDLLAP.FRM", "COPYFILE.TXT")
  464.  
  465.     If rc < 0 Then MsgBox "CopyFile Function failed!", 48, "CopyFile Error #" & rc
  466.  
  467. End Sub
  468.  
  469. Sub FindExample ()
  470. '
  471. '  Sample of FindString usage
  472. '
  473. '  Many thanks to Jim Moran at Honeywell for the challenge of
  474. '  this example!
  475. '
  476. '  Don't forget to check out CatStrFind() in the help file!
  477. '
  478.  Dim SrcString    As String
  479.  Dim TargetString As String
  480.  Dim locn         As Long
  481.  Dim InStrTime
  482.  Dim FindStringTime
  483.  Dim ii           As Integer
  484.  
  485.     
  486.     SrcString = String$(32000, "A") + "BBB"
  487.     TargetString = "AAAAAAAAAAAABBB"
  488.  
  489.     ' first show how InStr performs
  490.     
  491.     Screen.MousePointer = 11
  492.     InStrTime = Timer
  493.     For ii = 1 To 10
  494.  
  495.         locn = InStr(1, SrcString, TargetString)
  496.  
  497.     Next
  498.     InStrTime = Timer - InStrTime
  499.     Screen.MousePointer = 0
  500.  
  501.     MsgBox "(Found At " & locn & ") InStr took " & Format$(InStrTime / 10, "###.###0") & " seconds."
  502.     
  503.     ' now show how FindString performs
  504.     
  505.     Screen.MousePointer = 11
  506.     FindStringTime = Timer
  507.     For ii = 1 To 10
  508.  
  509.         locn = FindString(1, SrcString, TargetString)
  510.  
  511.     Next
  512.     FindStringTime = Timer - FindStringTime
  513.     Screen.MousePointer = 0
  514.  
  515.     MsgBox "(Found At " & locn & ") FindString took " & Format$(FindStringTime / 10, "###.###0") & " seconds."
  516.     
  517.     If FindStringTime < InStrTime Then
  518.  
  519.         MsgBox "FindString was " & Format$(InStrTime / FindStringTime, "###.###0") & " times faster."
  520.  
  521.     Else
  522.         
  523.         MsgBox "InStr was " & Format$(FindStringTime / InStrTime, "###.###0") & " times faster."
  524.     
  525.     End If
  526.     
  527. End Sub
  528.  
  529. Sub Form_Load ()
  530.  
  531.     On Error Resume Next
  532.  
  533.     CenterForm Me, 0, 0
  534.     ChDir App.Path
  535.  
  536.     Me.Top = Screen.Height * .05
  537.     Me.Height = Screen.Height * .9
  538.     Me.Left = Screen.Width * .05
  539.     Me.Width = Screen.Width * .9
  540.  
  541.     Me.Show
  542.  
  543. End Sub
  544.  
  545. Sub Form_Paint ()
  546.  
  547.     Outlines Me
  548.  
  549. End Sub
  550.  
  551. Sub Form_Resize ()
  552.  
  553.     On Error Resume Next
  554.  
  555.     Monitor.Top = ToolBar.Height + 120
  556.     Monitor.Left = 120
  557.     Monitor.Width = ScaleWidth - 240
  558.     Monitor.Height = ScaleHeight - ToolBar.Height - 240
  559.     List.Width = ScaleWidth - List.Left - 120
  560.  
  561. End Sub
  562.  
  563. '
  564. ' This subroutine demonstrates how CatStr (and ArrayStr) Objects
  565. ' can be passed to other functions using only the handle.
  566. '
  567. Sub HintMsg (CHandle As Integer, Title As String)
  568.  
  569.     HintDialog.Caption = Title
  570.     HintDialog.Hint = CatStrCopy(CHandle)
  571.     HintDialog.Show 1
  572.  
  573. End Sub
  574.  
  575. Sub LocateCode (Head As String, Tail As String)
  576. '
  577. ' This subroutine is used by the demonstration program to
  578. ' read the form file, locate the desired subroutine (beginning and
  579. ' end) and then highlight the text.
  580. '
  581. ' It also serves as an example of the FindStringIC function.
  582. '
  583.  
  584.  Dim File    As Integer  ' file handle to load STRDLLAP.FRM
  585.  Dim Buf     As String   ' line buffer
  586.  Dim CHandle As Integer  ' CatStr Object handle
  587.  Dim rc      As Integer  ' return code
  588.  Dim Looping As Integer  ' looping switch while reading file
  589.  Dim locn    As Long     ' location pointer for FindStringIC
  590.  Dim length  As Long     ' calculated length of located text
  591.  
  592.     ' locate a free file handle
  593.  
  594.     MousePointer = 11
  595.     List.Clear
  596.     Monitor.Visible = False
  597.     Monitor = ""
  598.  
  599.     File = FreeFile
  600.  
  601.     ' create a new CatStr object
  602.  
  603.     CHandle = CreateNewCatString(32768)
  604.  
  605.     ' open and read the file
  606.     
  607.     Open "STRDLLAPP.FRM" For Input As #File
  608.  
  609.     Looping = True
  610.     While Not EOF(File) And Looping
  611.  
  612.         Line Input #File, Buf
  613.  
  614.         ' use the CatStr object to buffer the
  615.         ' lines read from the file
  616.  
  617.         rc = CatStrAddLine(CHandle, Buf)
  618.  
  619.         '
  620.         ' stop if no more room in the buffer
  621.         '
  622.         If rc < 0 Then ' can't read any more
  623.             Looping = False
  624.         End If
  625.  
  626.     Wend
  627.  
  628.     Close #File
  629.     
  630.     '
  631.     ' search for the subroutine declaration
  632.     '
  633.     locn = CatStrFind(CHandle, 1, Head)
  634.     
  635.     '
  636.     ' As long as you haven't fiddled with the code
  637.     ' this should work
  638.     '
  639.     If locn > 0 Then
  640.     
  641.         length = CatStrFind(CHandle, locn, Tail) - locn + Len(Tail) - 1
  642.         Monitor = CatStrMid$(CHandle, locn, length)
  643.     
  644.     Else
  645.  
  646.         MsgBox "This example requires an un-modified version of STRDLLAPP.FRM", 48, "Demo Error"
  647.  
  648.     End If
  649.  
  650.     '
  651.     ' ALWAYS REMEMBER TO DESTROY THE OBJECT WHEN FINISHED
  652.     '
  653.  
  654.     DestroyCatString CHandle
  655.  
  656.     MousePointer = 0
  657.     Monitor.Visible = True
  658.     Monitor.SetFocus
  659.  
  660. End Sub
  661.  
  662. Sub Monitor_KeyPress (KeyAscii As Integer)
  663.  
  664.     KeyAscii = 0
  665.  
  666. End Sub
  667.  
  668. Sub Outlines (FormName As Form)
  669.     
  670. Dim drkgray     As Long
  671. Dim fullwhite   As Long
  672. Dim i           As Integer
  673. Dim ctop        As Integer
  674. Dim cleft       As Integer
  675. Dim cright      As Integer
  676. Dim cbottom     As Integer
  677. Dim Offset      As Integer
  678.  
  679.     On Error Resume Next
  680.     
  681.     Dim cName As Control
  682.     Offset = 0
  683.  
  684.     FormName.Cls
  685.     
  686.     drkgray = RGB(128, 128, 128)
  687.     fullwhite = RGB(255, 255, 255)
  688.  
  689.     For i = 0 To (FormName.Controls.Count - 1)
  690.         
  691.         Set cName = FormName.Controls(i)
  692.  
  693.         If TypeOf cName Is Menu Then
  694.  
  695.             GoTo SkipThisControl
  696.             
  697.         End If
  698.             
  699.         
  700.         If (UCase(cName.Tag) = "OL") Then
  701.                 
  702.             ctop = cName.Top - Screen.TwipsPerPixelY
  703.             cleft = cName.Left - Screen.TwipsPerPixelX
  704.             cright = cName.Left + cName.Width + (Screen.TwipsPerPixelX * Offset)
  705.             cbottom = cName.Top + cName.Height + (Screen.TwipsPerPixelY * Offset)
  706.             
  707.             FormName.Line (cleft, ctop)-(cright, ctop), drkgray
  708.             FormName.Line (cleft, ctop)-(cleft, cbottom), drkgray
  709.             FormName.Line (cleft, cbottom)-(cright, cbottom), fullwhite
  710.             FormName.Line (cright, ctop)-(cright, cbottom), fullwhite
  711.         
  712.         End If
  713.  
  714. SkipThisControl:
  715.     
  716.     Next i
  717.  
  718. End Sub
  719.  
  720. Sub ToolBar_Click ()
  721.  
  722.     Outlines Me
  723.  
  724. End Sub
  725.  
  726.