home *** CD-ROM | disk | FTP | other *** search
/ Visual Basic 4 Unleashed / Visual_Basic_4_Unleashed_SAMS_Publishing_1995.iso / crystal / extras / ocx30_32 / main.frm (.txt) < prev    next >
Encoding:
Visual Basic Form  |  1995-08-18  |  49.1 KB  |  1,331 lines

  1. VERSION 4.00
  2. Begin VB.Form Main 
  3.    BorderStyle     =   3  'Fixed Dialog
  4.    Caption         =   "Crystal Reports OCX Demo Application"
  5.    ClientHeight    =   6375
  6.    ClientLeft      =   870
  7.    ClientTop       =   1425
  8.    ClientWidth     =   10260
  9.    Height          =   6780
  10.    Icon            =   "Main.frx":0000
  11.    Left            =   810
  12.    LinkTopic       =   "Form1"
  13.    LockControls    =   -1  'True
  14.    MaxButton       =   0   'False
  15.    MinButton       =   0   'False
  16.    ScaleHeight     =   425
  17.    ScaleMode       =   3  'Pixel
  18.    ScaleWidth      =   684
  19.    ShowInTaskbar   =   0   'False
  20.    Top             =   1080
  21.    Width           =   10380
  22.    Begin VB.Timer Timer1 
  23.       Left            =   9600
  24.       Top             =   0
  25.    End
  26.    Begin VB.CommandButton CmdCancel 
  27.       Caption         =   "Cancel"
  28.       Height          =   375
  29.       Left            =   8400
  30.       TabIndex        =   17
  31.       Top             =   5760
  32.       Width           =   1575
  33.    End
  34.    Begin VB.CommandButton CmdAccept 
  35.       Caption         =   "Print Report"
  36.       Height          =   375
  37.       Left            =   6720
  38.       TabIndex        =   16
  39.       Top             =   5760
  40.       Width           =   1455
  41.    End
  42.    Begin VB.CommandButton CmdNext 
  43.       Caption         =   "Next >>"
  44.       Height          =   375
  45.       Left            =   2040
  46.       TabIndex        =   15
  47.       Top             =   5760
  48.       Width           =   1455
  49.    End
  50.    Begin VB.CommandButton CmdBack 
  51.       Caption         =   "<< Back "
  52.       Height          =   375
  53.       Left            =   360
  54.       TabIndex        =   14
  55.       Top             =   5760
  56.       Width           =   1455
  57.    End
  58.    Begin TabDlg.SSTab MainTab 
  59.       Height          =   5415
  60.       Left            =   360
  61.       TabIndex        =   0
  62.       Top             =   240
  63.       Width           =   9615
  64.       _Version        =   65536
  65.       _ExtentX        =   16960
  66.       _ExtentY        =   9551
  67.       _StockProps     =   15
  68.       Caption         =   "Set Report Formulas"
  69.       TabsPerRow      =   5
  70.       Tab             =   3
  71.       TabOrientation  =   0
  72.       Tabs            =   5
  73.       Style           =   1
  74.       TabMaxWidth     =   265
  75.       TabHeight       =   529
  76.       TabCaption(0)   =   "Open a Crystal Report"
  77.       Tab(0).ControlCount=   1
  78.       Tab(0).ControlEnabled=   0   'False
  79.       Tab(0).Control(0)=   "Frame1"
  80.       TabCaption(1)   =   "Destination"
  81.       Tab(1).ControlCount=   1
  82.       Tab(1).ControlEnabled=   0   'False
  83.       Tab(1).Control(0)=   "Frame4"
  84.       TabCaption(2)   =   "Database Location"
  85.       Tab(2).ControlCount=   1
  86.       Tab(2).ControlEnabled=   0   'False
  87.       Tab(2).Control(0)=   "Frame9"
  88.       TabCaption(3)   =   "Set Report Formulas"
  89.       Tab(3).ControlCount=   1
  90.       Tab(3).ControlEnabled=   -1  'True
  91.       Tab(3).Control(0)=   "Frame5"
  92.       TabCaption(4)   =   "About the OCX Demo"
  93.       Tab(4).ControlCount=   1
  94.       Tab(4).ControlEnabled=   0   'False
  95.       Tab(4).Control(0)=   "Frame20"
  96.       Begin VB.Frame Frame20 
  97.          Height          =   4695
  98.          Left            =   -74760
  99.          TabIndex        =   81
  100.          Top             =   480
  101.          Width           =   9135
  102.          Begin VB.Frame Frame23 
  103.             Height          =   2655
  104.             Left            =   120
  105.             TabIndex        =   83
  106.             Top             =   1920
  107.             Width           =   8895
  108.             Begin VB.Label Label23 
  109.                Caption         =   "800-877-2340 (U.S.)  800-663-1244 (Canada)  604-681-3435                E-Mail: sales@crystalinc.com"
  110.                Height          =   855
  111.                Left            =   3600
  112.                TabIndex        =   105
  113.                Top             =   1680
  114.                Width           =   2175
  115.             End
  116.             Begin VB.Label Label22 
  117.                Caption         =   "You can also Contact Crystal directly at:"
  118.                Height          =   255
  119.                Left            =   480
  120.                TabIndex        =   104
  121.                Top             =   1680
  122.                Width           =   3015
  123.             End
  124.             Begin VB.Label Label21 
  125.                Caption         =   "Or, GO REPORTS on CompuServe to visit the Crystal Reports section of the Windows Components B Forum"
  126.                Height          =   255
  127.                Left            =   480
  128.                TabIndex        =   103
  129.                Top             =   1440
  130.                Width           =   7935
  131.             End
  132.             Begin VB.Label Label19 
  133.                Alignment       =   2  'Center
  134.                Caption         =   $"Main.frx":030A
  135.                Height          =   495
  136.                Left            =   360
  137.                TabIndex        =   102
  138.                Top             =   960
  139.                Width           =   8055
  140.             End
  141.             Begin VB.Label Label16 
  142.                Alignment       =   2  'Center
  143.                Caption         =   "Crystal Reports is the #1 award-winning reporting tool  with over 1 million copies shipped."
  144.                Height          =   255
  145.                Left            =   1200
  146.                TabIndex        =   88
  147.                Top             =   720
  148.                Width           =   6375
  149.             End
  150.             Begin VB.Label Label15 
  151.                Alignment       =   2  'Center
  152.                Caption         =   "Copyright 
  153.  1995 Crystal Computer Services Inc.  A Seagate Software Company"
  154.                Height          =   495
  155.                Left            =   2640
  156.                TabIndex        =   87
  157.                Top             =   240
  158.                Width           =   3615
  159.             End
  160.          End
  161.          Begin VB.Frame Frame22 
  162.             Height          =   1695
  163.             Left            =   120
  164.             TabIndex        =   82
  165.             Top             =   120
  166.             Width           =   8895
  167.             Begin VB.PictureBox Picture1 
  168.                AutoSize        =   -1  'True
  169.                Height          =   510
  170.                Left            =   240
  171.                Picture         =   "Main.frx":03B7
  172.                ScaleHeight     =   480
  173.                ScaleWidth      =   480
  174.                TabIndex        =   86
  175.                Top             =   360
  176.                Width           =   510
  177.             End
  178.             Begin VB.Label Label14 
  179.                Alignment       =   2  'Center
  180.                Caption         =   $"Main.frx":06C1
  181.                Height          =   855
  182.                Left            =   840
  183.                TabIndex        =   85
  184.                Top             =   720
  185.                Width           =   7455
  186.             End
  187.             Begin VB.Label Label13 
  188.                Alignment       =   2  'Center
  189.                Caption         =   "Crystal Reports for Visual Basic Professional 4.0 Sample Application using the Crystal 32-Bit OLE Control."
  190.                Height          =   615
  191.                Left            =   1800
  192.                TabIndex        =   84
  193.                Top             =   240
  194.                Width           =   5055
  195.             End
  196.          End
  197.       End
  198.       Begin VB.Frame Frame9 
  199.          Height          =   4695
  200.          Left            =   -74760
  201.          TabIndex        =   10
  202.          Top             =   480
  203.          Width           =   9135
  204.          Begin VB.CommandButton CmdSecurity 
  205.             Caption         =   "Set Security"
  206.             Enabled         =   0   'False
  207.             Height          =   375
  208.             Left            =   5160
  209.             TabIndex        =   68
  210.             Top             =   4200
  211.             Width           =   1575
  212.          End
  213.          Begin VB.CommandButton CmdConnect 
  214.             Caption         =   "Connect"
  215.             Height          =   375
  216.             Left            =   7200
  217.             TabIndex        =   67
  218.             Top             =   4200
  219.             Width           =   1815
  220.          End
  221.          Begin VB.Frame Frame14 
  222.             Caption         =   "ODBC Connection:"
  223.             Height          =   1095
  224.             Left            =   120
  225.             TabIndex        =   51
  226.             Top             =   240
  227.             Width           =   8895
  228.             Begin VB.TextBox TxtDSQ 
  229.                Height          =   285
  230.                Left            =   6120
  231.                TabIndex        =   66
  232.                Top             =   600
  233.                Width           =   2655
  234.             End
  235.             Begin VB.TextBox TxtPWD 
  236.                Height          =   285
  237.                Left            =   1800
  238.                PasswordChar    =   "*"
  239.                TabIndex        =   65
  240.                Top             =   600
  241.                Width           =   2535
  242.             End
  243.             Begin VB.TextBox TxtUID 
  244.                Height          =   285
  245.                Left            =   6120
  246.                TabIndex        =   62
  247.                Top             =   240
  248.                Width           =   2655
  249.             End
  250.             Begin VB.TextBox TxtDSN 
  251.                Height          =   285
  252.                Left            =   1800
  253.                TabIndex        =   59
  254.                Top             =   240
  255.                Width           =   2535
  256.             End
  257.             Begin VB.Label Label8 
  258.                Caption         =   "Database Qualifier:"
  259.                Height          =   255
  260.                Left            =   4440
  261.                TabIndex        =   64
  262.                Top             =   720
  263.                Width           =   1455
  264.             End
  265.             Begin VB.Label Label7 
  266.                Caption         =   "User ID:"
  267.                Height          =   255
  268.                Left            =   4440
  269.                TabIndex        =   63
  270.                Top             =   360
  271.                Width           =   1095
  272.             End
  273.             Begin VB.Label Label6 
  274.                Caption         =   "Password:"
  275.                Height          =   255
  276.                Left            =   240
  277.                TabIndex        =   61
  278.                Top             =   720
  279.                Width           =   1455
  280.             End
  281.             Begin VB.Label Label3 
  282.                Caption         =   "Data Source Name:"
  283.                Height          =   255
  284.                Left            =   240
  285.                TabIndex        =   60
  286.                Top             =   360
  287.                Width           =   1455
  288.             End
  289.          End
  290.          Begin VB.Frame Frame6 
  291.             Caption         =   "Database/Access Security:"
  292.             Height          =   2655
  293.             Left            =   120
  294.             TabIndex        =   41
  295.             Top             =   1440
  296.             Width           =   8895
  297.             Begin VB.Frame Frame13 
  298.                Caption         =   "Database:"
  299.                Height          =   2295
  300.                Left            =   3600
  301.                TabIndex        =   45
  302.                Top             =   240
  303.                Width           =   5175
  304.                Begin VB.TextBox TxtPassword 
  305.                   Height          =   285
  306.                   Left            =   2760
  307.                   MaxLength       =   14
  308.                   PasswordChar    =   "*"
  309.                   TabIndex        =   48
  310.                   Top             =   1800
  311.                   Width           =   2295
  312.                End
  313.                Begin VB.TextBox TxtUserName 
  314.                   Height          =   285
  315.                   Left            =   120
  316.                   MaxLength       =   20
  317.                   TabIndex        =   47
  318.                   Top             =   1800
  319.                   Width           =   2295
  320.                End
  321.                Begin VB.FileListBox DataFileList 
  322.                   Height          =   1005
  323.                   Left            =   120
  324.                   Pattern         =   "*.mdb"
  325.                   TabIndex        =   46
  326.                   Top             =   240
  327.                   Width           =   4935
  328.                End
  329.                Begin VB.Label Label5 
  330.                   Caption         =   "Password:"
  331.                   Height          =   255
  332.                   Left            =   2760
  333.                   TabIndex        =   50
  334.                   Top             =   1560
  335.                   Width           =   2295
  336.                End
  337.                Begin VB.Label Label4 
  338.                   Caption         =   "User Name:"
  339.                   Height          =   255
  340.                   Left            =   120
  341.                   TabIndex        =   49
  342.                   Top             =   1560
  343.                   Width           =   2295
  344.                End
  345.             End
  346.             Begin VB.Frame Frame8 
  347.                Caption         =   "Directory:"
  348.                Height          =   2295
  349.                Left            =   120
  350.                TabIndex        =   42
  351.                Top             =   240
  352.                Width           =   3375
  353.                Begin VB.DirListBox DataDirList 
  354.                   Height          =   1380
  355.                   Left            =   120
  356.                   TabIndex        =   44
  357.                   Top             =   240
  358.                   Width           =   3135
  359.                End
  360.                Begin VB.DriveListBox DataDriveList 
  361.                   Height          =   315
  362.                   Left            =   120
  363.                   TabIndex        =   43
  364.                   Top             =   1800
  365.                   Width           =   3135
  366.                End
  367.             End
  368.          End
  369.       End
  370.       Begin VB.Frame Frame5 
  371.          Height          =   4695
  372.          Left            =   240
  373.          TabIndex        =   8
  374.          Top             =   480
  375.          Width           =   9015
  376.          Begin VB.CommandButton CmdClrFormula 
  377.             Caption         =   "Clear Formula Text"
  378.             Height          =   375
  379.             Left            =   7200
  380.             TabIndex        =   71
  381.             Top             =   4200
  382.             Width           =   1575
  383.          End
  384.          Begin VB.CommandButton CmdAccptFormula 
  385.             Caption         =   "Accept Formula"
  386.             Height          =   375
  387.             Left            =   5280
  388.             TabIndex        =   70
  389.             Top             =   4200
  390.             Width           =   1575
  391.          End
  392.          Begin TabDlg.SSTab FormulaTab 
  393.             Height          =   3735
  394.             Left            =   240
  395.             TabIndex        =   9
  396.             Top             =   360
  397.             Width           =   8535
  398.             _Version        =   65536
  399.             _ExtentX        =   15055
  400.             _ExtentY        =   6588
  401.             _StockProps     =   15
  402.             Caption         =   "Report Formula"
  403.             TabsPerRow      =   4
  404.             Tab             =   0
  405.             TabOrientation  =   0
  406.             Tabs            =   4
  407.             Style           =   1
  408.             TabMaxWidth     =   0
  409.             TabHeight       =   529
  410.             TabCaption(0)   =   "Report Formula"
  411.             Tab(0).ControlCount=   1
  412.             Tab(0).ControlEnabled=   -1  'True
  413.             Tab(0).Control(0)=   "Frame10"
  414.             TabCaption(1)   =   "Record Selection Formula"
  415.             Tab(1).ControlCount=   1
  416.             Tab(1).ControlEnabled=   0   'False
  417.             Tab(1).Control(0)=   "Frame11"
  418.             TabCaption(2)   =   "Group Selection Formula"
  419.             Tab(2).ControlCount=   1
  420.             Tab(2).ControlEnabled=   0   'False
  421.             Tab(2).Control(0)=   "Frame12"
  422.             TabCaption(3)   =   "Record/Group Sort Orders"
  423.             Tab(3).ControlCount=   1
  424.             Tab(3).ControlEnabled=   0   'False
  425.             Tab(3).Control(0)=   "Frame16"
  426.             Begin VB.Frame Frame16 
  427.                Height          =   3015
  428.                Left            =   -74760
  429.                TabIndex        =   73
  430.                Top             =   480
  431.                Width           =   8055
  432.                Begin VB.Frame Frame18 
  433.                   Caption         =   "Group Sort Order"
  434.                   Height          =   2655
  435.                   Left            =   4080
  436.                   TabIndex        =   75
  437.                   Top             =   240
  438.                   Width           =   3855
  439.                   Begin VB.CommandButton CmdGrpClear 
  440.                      Caption         =   "Clear G&roup Sort"
  441.                      Height          =   375
  442.                      Left            =   2160
  443.                      TabIndex        =   98
  444.                      Top             =   2160
  445.                      Width           =   1500
  446.                   End
  447.                   Begin VB.CommandButton CmdGrpSort 
  448.                      Caption         =   "Set &Group Sort"
  449.                      Height          =   375
  450.                      Left            =   240
  451.                      TabIndex        =   97
  452.                      Top             =   2160
  453.                      Width           =   1500
  454.                   End
  455.                   Begin VB.OptionButton OptGrpSort 
  456.                      Caption         =   "Descending"
  457.                      Height          =   255
  458.                      Index           =   1
  459.                      Left            =   2040
  460.                      TabIndex        =   96
  461.                      Top             =   840
  462.                      Width           =   1575
  463.                   End
  464.                   Begin VB.OptionButton OptGrpSort 
  465.                      Caption         =   "Ascending"
  466.                      Height          =   255
  467.                      Index           =   0
  468.                      Left            =   120
  469.                      TabIndex        =   95
  470.                      Top             =   840
  471.                      Value           =   -1  'True
  472.                      Width           =   1935
  473.                   End
  474.                   Begin VB.TextBox TxtGrpSort 
  475.                      Height          =   285
  476.                      Left            =   120
  477.                      TabIndex        =   94
  478.                      Top             =   360
  479.                      Width           =   3615
  480.                   End
  481.                   Begin VB.Label Label24 
  482.                      Caption         =   "e.g. Sum ({empdata.salary}, {empdata.empnum})"
  483.                      Height          =   255
  484.                      Left            =   240
  485.                      TabIndex        =   106
  486.                      Top             =   1850
  487.                      Width           =   3495
  488.                   End
  489.                   Begin VB.Label Label20 
  490.                      Caption         =   "The group field being entered into the textbox must be entered using the same syntax as is entered into Crystal Reports."
  491.                      Height          =   615
  492.                      Left            =   240
  493.                      TabIndex        =   99
  494.                      Top             =   1200
  495.                      Width           =   3495
  496.                   End
  497.                End
  498.                Begin VB.Frame Frame17 
  499.                   Caption         =   "Record Sort Order"
  500.                   Height          =   2655
  501.                   Left            =   120
  502.                   TabIndex        =   74
  503.                   Top             =   240
  504.                   Width           =   3855
  505.                   Begin VB.CommandButton CmdRecSort 
  506.                      Caption         =   "&Set Record Sort"
  507.                      Height          =   375
  508.                      Left            =   240
  509.                      TabIndex        =   93
  510.                      Top             =   2160
  511.                      Width           =   1500
  512.                   End
  513.                   Begin VB.CommandButton CmdRecClear 
  514.                      Caption         =   "&Clear Record Sort"
  515.                      Height          =   375
  516.                      Left            =   2160
  517.                      TabIndex        =   92
  518.                      Top             =   2160
  519.                      Width           =   1500
  520.                   End
  521.                   Begin VB.OptionButton OptRecSort 
  522.                      Caption         =   "Descending"
  523.                      Height          =   255
  524.                      Index           =   1
  525.                      Left            =   2040
  526.                      TabIndex        =   90
  527.                      Top             =   840
  528.                      Width           =   1335
  529.                   End
  530.                   Begin VB.OptionButton OptRecSort 
  531.                      Caption         =   "Ascending"
  532.                      Height          =   255
  533.                      Index           =   0
  534.                      Left            =   120
  535.                      TabIndex        =   89
  536.                      Top             =   840
  537.                      Value           =   -1  'True
  538.                      Width           =   1095
  539.                   End
  540.                   Begin VB.TextBox TxtRecSort 
  541.                      Height          =   285
  542.                      Left            =   120
  543.                      TabIndex        =   76
  544.                      Top             =   360
  545.                      Width           =   3615
  546.                   End
  547.                   Begin VB.Label Label17 
  548.                      Caption         =   "e.g. {Empdata.Salary}"
  549.                      Height          =   255
  550.                      Left            =   120
  551.                      TabIndex        =   100
  552.                      Top             =   1850
  553.                      Width           =   3495
  554.                   End
  555.                   Begin VB.Label Label18 
  556.                      Caption         =   $"Main.frx":0829
  557.                      Height          =   615
  558.                      Left            =   120
  559.                      TabIndex        =   91
  560.                      Top             =   1200
  561.                      Width           =   3375
  562.                   End
  563.                End
  564.             End
  565.             Begin VB.CommandButton CmdAccptFormulas 
  566.                Caption         =   "Accept Formula"
  567.                Height          =   375
  568.                Left            =   -68400
  569.                TabIndex        =   69
  570.                Top             =   3600
  571.                Width           =   1695
  572.             End
  573.             Begin VB.Frame Frame12 
  574.                Height          =   3015
  575.                Left            =   -74760
  576.                TabIndex        =   13
  577.                Top             =   480
  578.                Width           =   8055
  579.                Begin VB.Frame Frame21 
  580.                   Height          =   975
  581.                   Left            =   120
  582.                   TabIndex        =   80
  583.                   Top             =   1920
  584.                   Width           =   7815
  585.                   Begin VB.Label Label12 
  586.                      Caption         =   $"Main.frx":08C3
  587.                      Height          =   615
  588.                      Left            =   120
  589.                      TabIndex        =   101
  590.                      Top             =   240
  591.                      Width           =   7575
  592.                   End
  593.                End
  594.                Begin VB.TextBox TxtGrpSelFormula 
  595.                   Height          =   1695
  596.                   Left            =   120
  597.                   MultiLine       =   -1  'True
  598.                   ScrollBars      =   2  'Vertical
  599.                   TabIndex        =   58
  600.                   Top             =   240
  601.                   Width           =   7815
  602.                End
  603.                Begin VB.Label Label9 
  604.                   Height          =   855
  605.                   Left            =   120
  606.                   TabIndex        =   77
  607.                   Top             =   2040
  608.                   Width           =   7815
  609.                End
  610.             End
  611.             Begin VB.Frame Frame11 
  612.                Height          =   3015
  613.                Left            =   -74760
  614.                TabIndex        =   12
  615.                Top             =   480
  616.                Width           =   8055
  617.                Begin VB.Frame Frame19 
  618.                   Height          =   975
  619.                   Left            =   120
  620.                   TabIndex        =   78
  621.                   Top             =   1920
  622.                   Width           =   7815
  623.                   Begin VB.Label Label11 
  624.                      Caption         =   $"Main.frx":09DB
  625.                      Height          =   615
  626.                      Left            =   120
  627.                      TabIndex        =   79
  628.                      Top             =   240
  629.                      Width           =   7575
  630.                   End
  631.                End
  632.                Begin VB.TextBox TxtRecSelFormula 
  633.                   Height          =   1695
  634.                   Left            =   120
  635.                   MultiLine       =   -1  'True
  636.                   ScrollBars      =   2  'Vertical
  637.                   TabIndex        =   57
  638.                   Top             =   240
  639.                   Width           =   7815
  640.                End
  641.             End
  642.             Begin VB.Frame Frame10 
  643.                Height          =   3015
  644.                Left            =   240
  645.                TabIndex        =   11
  646.                Top             =   480
  647.                Width           =   8055
  648.                Begin VB.Frame Frame15 
  649.                   Caption         =   "Formula Text:"
  650.                   Height          =   2055
  651.                   Left            =   120
  652.                   TabIndex        =   55
  653.                   Top             =   840
  654.                   Width           =   7815
  655.                   Begin VB.TextBox TxtFormula 
  656.                      Height          =   1695
  657.                      Left            =   120
  658.                      MaxLength       =   255
  659.                      MultiLine       =   -1  'True
  660.                      ScrollBars      =   2  'Vertical
  661.                      TabIndex        =   56
  662.                      Top             =   240
  663.                      Width           =   7575
  664.                   End
  665.                End
  666.                Begin VB.TextBox TxtFormulaName 
  667.                   Height          =   285
  668.                   Left            =   1560
  669.                   TabIndex        =   53
  670.                   Top             =   360
  671.                   Width           =   2655
  672.                End
  673.                Begin VB.Label Label2 
  674.                   Caption         =   "This formula must be entered using the same syntax of the Formula Editor."
  675.                   Height          =   375
  676.                   Left            =   4440
  677.                   TabIndex        =   54
  678.                   Top             =   360
  679.                   Width           =   3375
  680.                End
  681.                Begin VB.Label Label1 
  682.                   Caption         =   "Formula Name:"
  683.                   Height          =   255
  684.                   Left            =   180
  685.                   TabIndex        =   52
  686.                   Top             =   480
  687.                   Width           =   1215
  688.                End
  689.             End
  690.          End
  691.          Begin VB.Label Label10 
  692.             Caption         =   $"Main.frx":0AF5
  693.             Height          =   405
  694.             Left            =   240
  695.             TabIndex        =   72
  696.             Top             =   4200
  697.             Width           =   5055
  698.          End
  699.       End
  700.       Begin VB.Frame Frame4 
  701.          Height          =   4695
  702.          Left            =   -74640
  703.          TabIndex        =   7
  704.          Top             =   480
  705.          Width           =   9015
  706.          Begin VB.Frame FrmPrinter 
  707.             Caption         =   "Print to a Printer:"
  708.             Height          =   735
  709.             Left            =   3840
  710.             TabIndex        =   21
  711.             Top             =   1080
  712.             Width           =   5055
  713.             Begin VB.TextBox TxtPrnCopies 
  714.                Height          =   315
  715.                Left            =   3840
  716.                TabIndex        =   40
  717.                Text            =   "1"
  718.                Top             =   280
  719.                Width           =   495
  720.             End
  721.             Begin Spin.SpinButton SpinButton1 
  722.                Height          =   315
  723.                Left            =   4560
  724.                TabIndex        =   39
  725.                Top             =   285
  726.                Width           =   375
  727.                _Version        =   65536
  728.                _ExtentX        =   661
  729.                _ExtentY        =   556
  730.                _StockProps     =   73
  731.                ForeColor       =   12632256
  732.                TdThickness     =   2
  733.             End
  734.             Begin VB.Label LblPrnCopies 
  735.                Caption         =   "Number of Copies to send to Printer:"
  736.                Height          =   255
  737.                Left            =   120
  738.                TabIndex        =   37
  739.                Top             =   360
  740.                Width           =   2655
  741.             End
  742.          End
  743.          Begin VB.Frame FrmWin 
  744.             Caption         =   "Print to a Window:"
  745.             Height          =   735
  746.             Left            =   3840
  747.             TabIndex        =   20
  748.             Top             =   240
  749.             Width           =   5055
  750.             Begin VB.TextBox TxtWinTitle 
  751.                Height          =   285
  752.                Left            =   1560
  753.                TabIndex        =   32
  754.                Top             =   240
  755.                Width           =   3375
  756.             End
  757.             Begin VB.Label LblWinTitle 
  758.                Caption         =   "Window Title:"
  759.                Height          =   255
  760.                Left            =   120
  761.                TabIndex        =   38
  762.                Top             =   360
  763.                Width           =   1215
  764.             End
  765.          End
  766.          Begin VB.Frame Frame7 
  767.             BackColor       =   &H00C0C0C0&
  768.             Caption         =   "Destination Selection:"
  769.             Height          =   1575
  770.             Left            =   120
  771.             TabIndex        =   19
  772.             Top             =   240
  773.             Width           =   3615
  774.             Begin VB.OptionButton OptFile 
  775.                BackColor       =   &H00C0C0C0&
  776.                Caption         =   "Print to a File"
  777.                Height          =   255
  778.                Left            =   360
  779.                TabIndex        =   35
  780.                Top             =   1080
  781.                Width           =   1575
  782.             End
  783.             Begin VB.OptionButton OptPrinter 
  784.                Caption         =   "Print to a Printer"
  785.                Height          =   255
  786.                Left            =   360
  787.                TabIndex        =   34
  788.                Top             =   720
  789.                Width           =   1455
  790.             End
  791.             Begin VB.OptionButton OptWindow 
  792.                BackColor       =   &H00C0C0C0&
  793.                Caption         =   "Print to a Window"
  794.                Height          =   255
  795.                Left            =   360
  796.                TabIndex        =   33
  797.                Top             =   360
  798.                Width           =   1575
  799.             End
  800.          End
  801.          Begin VB.Frame FrmFile 
  802.             Caption         =   "Print to File:"
  803.             ForeColor       =   &H00000000&
  804.             Height          =   2655
  805.             Left            =   120
  806.             TabIndex        =   18
  807.             Top             =   1920
  808.             Width           =   8775
  809.             Begin VB.TextBox TxtPrnFileName 
  810.                Height          =   285
  811.                Left            =   5880
  812.                TabIndex        =   31
  813.                Top             =   360
  814.                Width           =   2775
  815.             End
  816.             Begin VB.Frame FrmFileType 
  817.                Caption         =   "File Type:"
  818.                Height          =   1335
  819.                Left            =   4440
  820.                TabIndex        =   24
  821.                Top             =   1200
  822.                Width           =   4215
  823.                Begin VB.OptionButton OptTabSepText 
  824.                   Caption         =   "Tab-Seperated Text"
  825.                   Height          =   255
  826.                   Left            =   2040
  827.                   TabIndex        =   30
  828.                   Top             =   960
  829.                   Width           =   1815
  830.                End
  831.                Begin VB.OptionButton OptRecord 
  832.                   Caption         =   "Record"
  833.                   Height          =   255
  834.                   Left            =   2040
  835.                   TabIndex        =   29
  836.                   Top             =   600
  837.                   Width           =   1335
  838.                End
  839.                Begin VB.OptionButton OptText 
  840.                   Caption         =   "Text"
  841.                   Height          =   255
  842.                   Left            =   360
  843.                   TabIndex        =   28
  844.                   Top             =   240
  845.                   Width           =   855
  846.                End
  847.                Begin VB.OptionButton OptCSV 
  848.                   Caption         =   "CSV"
  849.                   Height          =   255
  850.                   Left            =   2040
  851.                   TabIndex        =   27
  852.                   Top             =   240
  853.                   Width           =   1215
  854.                End
  855.                Begin VB.OptionButton OptDIF 
  856.                   Caption         =   "DIF"
  857.                   Height          =   255
  858.                   Left            =   360
  859.                   TabIndex        =   26
  860.                   Top             =   600
  861.                   Width           =   975
  862.                End
  863.                Begin VB.OptionButton OptTabSep 
  864.                   Caption         =   "Tab-Seperated"
  865.                   Height          =   255
  866.                   Left            =   360
  867.                   TabIndex        =   25
  868.                   Top             =   960
  869.                   Width           =   1575
  870.                End
  871.             End
  872.             Begin VB.DirListBox PrnFileDir 
  873.                Height          =   1830
  874.                Left            =   120
  875.                TabIndex        =   23
  876.                Top             =   240
  877.                Width           =   2655
  878.             End
  879.             Begin VB.DriveListBox PrnFileDrive 
  880.                Height          =   315
  881.                Left            =   120
  882.                TabIndex        =   22
  883.                Top             =   2160
  884.                Width           =   2655
  885.             End
  886.             Begin VB.Label LblFileName 
  887.                Caption         =   "File Name:"
  888.                Height          =   255
  889.                Left            =   4560
  890.                TabIndex        =   36
  891.                Top             =   480
  892.                Width           =   975
  893.             End
  894.          End
  895.       End
  896.       Begin VB.Frame Frame1 
  897.          Height          =   4695
  898.          Left            =   -74640
  899.          TabIndex        =   1
  900.          Top             =   480
  901.          Width           =   9015
  902.          Begin VB.Frame Frame3 
  903.             Caption         =   "Reports:"
  904.             Height          =   4215
  905.             Left            =   3480
  906.             TabIndex        =   3
  907.             Top             =   240
  908.             Width           =   5415
  909.             Begin VB.FileListBox FileList 
  910.                DragIcon        =   "Main.frx":0B7F
  911.                Height          =   3735
  912.                Left            =   120
  913.                Pattern         =   "*.rpt"
  914.                TabIndex        =   6
  915.                Top             =   240
  916.                Width           =   5175
  917.             End
  918.          End
  919.          Begin VB.Frame Frame2 
  920.             Caption         =   "Directory:"
  921.             Height          =   4215
  922.             Left            =   240
  923.             TabIndex        =   2
  924.             Top             =   240
  925.             Width           =   3135
  926.             Begin VB.DriveListBox DriveList 
  927.                Height          =   315
  928.                Left            =   120
  929.                TabIndex        =   5
  930.                Top             =   3720
  931.                Width           =   2895
  932.             End
  933.             Begin VB.DirListBox DirList 
  934.                Height          =   3405
  935.                Left            =   120
  936.                TabIndex        =   4
  937.                Top             =   240
  938.                Width           =   2895
  939.             End
  940.          End
  941.       End
  942.    End
  943.    Begin Crystal.CrystalReport CrystalReport1 
  944.       Left            =   120
  945.       Top             =   0
  946.       _ExtentX        =   741
  947.       _ExtentY        =   741
  948.       _StockProps     =   0
  949.       ReportFileName  =   ""
  950.       Destination     =   0
  951.       WindowLeft      =   0
  952.       WindowTop       =   0
  953.       WindowWidth     =   640
  954.       WindowHeight    =   480
  955.       WindowTitle     =   ""
  956.       WindowBorderStyle=   2
  957.       WindowControlBox=   -1  'True
  958.       WindowMaxButton =   -1  'True
  959.       WindowMinButton =   -1  'True
  960.       CopiesToPrinter =   1
  961.       PrintFileName   =   ""
  962.       PrintFileType   =   0
  963.       SelectionFormula=   ""
  964.       GroupSelectionFormula=   ""
  965.       Connect         =   ""
  966.       UserName        =   ""
  967.       ReportSource    =   0
  968.       BoundReportHeading=   ""
  969.       BoundReportFooter=   0   'False
  970.    End
  971. Attribute VB_Name = "Main"
  972. Attribute VB_Creatable = False
  973. Attribute VB_Exposed = False
  974. Option Explicit
  975. Dim FormulaNum As Integer           ' Sets a variable to increment the CrystalReport1.Formulas
  976.                                     ' array index for each formula that is being set. This value
  977. Dim RecSort As Integer
  978. Dim grpsort As Integer
  979. Private Sub CmdAccept_Click()
  980. Dim iCrystalError As Integer
  981. On Error GoTo ErrorHandler
  982.     If CrystalReport1.Destination = 1 Then
  983.         CrystalReport1.CopiesToPrinter = Val(TxtPrnCopies.Text)
  984.     End If
  985.     CrystalReport1.Action = 1
  986.     ResetIndexes
  987. ErrorHandler:
  988.     iCrystalError = CrystalReport1.LastErrorNumber
  989.     PrintError (iCrystalError)
  990.     Exit Sub
  991. End Sub
  992. Private Sub CmdAccptFormula_Click()
  993. Dim sFormulaText As String                      ' create avariable to hold the formula text
  994.                                                 ' that is entered by the user.
  995. Dim iFormulaTabNum As Integer                   ' hold the number of the tab selected.
  996. iFormulaTabNum = FormulaTab.Tab                 ' assign the Formula Tab's active tab number to
  997.                                                 ' to the FormulaTabNum variable.
  998.                                                 
  999. ' Depending on the active tab chosen, determine what formula is being edited and then assign
  1000. ' the formula text to the appropriate formula property.
  1001. Select Case iFormulaTabNum
  1002. Case 0                  ' sets the value for the CrystalReport1.Formulas(0) array property.
  1003.     sFormulaText = TxtFormulaName.Text & "= " & TxtFormula.Text
  1004.     CrystalReport1.Formulas(FormulaNum) = sFormulaText
  1005.     FormulaNum = FormulaNum + 1                 ' increments the CrystalReport1.Formulas(0)
  1006.                                                 ' array index.
  1007. Case 1                                          ' Set the Record Selection Formula.
  1008.     CrystalReport1.SelectionFormula = TxtRecSelFormula.Text
  1009. Case 2                                          ' Set the Group Selection Formula.
  1010.     CrystalReport1.GroupSelectionFormula = TxtGrpSelFormula.Text
  1011. Case 3                                          ' Disables the "Accept Formula" command button
  1012.     CmdAccptFormula.Enabled = False             ' when the user chooses the Record/Group Sort
  1013.                                                 ' Orders tab.
  1014. End Select
  1015. End Sub
  1016. Private Sub CmdBack_Click()
  1017. If MainTab.Tab > 0 Then
  1018.     MainTab.Tab = MainTab.Tab - 1
  1019.     CmdNext.Enabled = True
  1020. End If
  1021. If MainTab.Tab < 1 Then
  1022.     CmdBack.Enabled = False
  1023. End If
  1024. End Sub
  1025. Private Sub CmdCancel_Click()
  1026.     End                                         ' Exit the program.
  1027. End Sub
  1028. Private Sub CmdClrFormula_Click()
  1029. Dim iClearTabNum As Integer
  1030. iClearTabNum = FormulaTab.Tab
  1031. Select Case iClearTabNum
  1032. Case 0
  1033.     TxtFormulaName.Text = " "
  1034.     TxtFormula.Text = " "
  1035.     CmdAccptFormula.Enabled = False
  1036. Case 1
  1037.     TxtRecSelFormula.Text = " "
  1038.     CmdAccptFormula.Enabled = False
  1039. Case 2
  1040.     TxtGrpSelFormula.Text = " "
  1041.     CmdAccptFormula.Enabled = False
  1042. End Select
  1043. End Sub
  1044. Private Sub CmdConnect_Click()
  1045. Dim sCnctStrng As String, sDataSrce As String, sUserID As String, sPwd As String, sDsqlfr As String
  1046. sDataSrce = "DSN=" & TxtDSN.Text
  1047. sUserID = "UID=" & TxtUID.Text
  1048. sPwd = "PWD=" & TxtPWD.Text
  1049. sDsqlfr = "DSQ=" & TxtDSQ.Text
  1050. 'if TxtPWD.TEXT = " "
  1051. CrystalReport1.Connect = sDataSrce & ";" & sUserID & ";" & sPwd & ";" & sDsqlfr
  1052. MsgBox CrystalReport1.Connect
  1053. End Sub
  1054. Private Sub CmdGrpClear_Click()
  1055. TxtGrpSort.Text = " "
  1056. End Sub
  1057. Private Sub CmdGrpSort_Click()
  1058. Dim sortgrp As String
  1059. If OptGrpSort(0).Value Then
  1060.     sortgrp = "+" & TxtGrpSort.Text
  1061.     sortgrp = "-" & TxtGrpSort.Text
  1062. End If
  1063.    CrystalReport1.GroupSortFields(grpsort) = sortgrp
  1064.     grpsort = grpsort + 1
  1065. End Sub
  1066. Private Sub CmdNext_Click()
  1067. If MainTab.Tab < MainTab.Tabs - 1 Then
  1068.     MainTab.Tab = MainTab.Tab + 1
  1069.     CmdBack.Enabled = True
  1070. End If
  1071. If MainTab.Tab = MainTab.Tabs - 1 Then
  1072.     CmdNext.Enabled = False
  1073. End If
  1074. End Sub
  1075. Private Sub CmdRecClear_Click()
  1076. TxtRecSort.Text = " "
  1077. End Sub
  1078. Private Sub CmdRecSort_Click()
  1079. Dim sort As String
  1080. If OptRecSort(0).Value Then
  1081.     sort = "+" & TxtRecSort.Text
  1082.     sort = "-" & TxtRecSort.Text
  1083. End If
  1084.    CrystalReport1.SortFields(RecSort) = sort
  1085.     RecSort = RecSort + 1
  1086. End Sub
  1087. Private Sub CmdSecurity_Click()
  1088. CrystalReport1.UserName = TxtUserName.Text
  1089. CrystalReport1.Password = TxtPassword.Text
  1090. End Sub
  1091. Private Sub DataDirList_Change()
  1092. DataFileList.Path = DataDirList.Path
  1093. End Sub
  1094. Private Sub DataDriveList_Change()
  1095. DataDirList.Path = DataDriveList.Drive
  1096. End Sub
  1097. Private Sub DataFileList_DblClick()
  1098. Dim sRptDataFile As String
  1099. sRptDataFile = DataFileList.Path & "\" & DataFileList.filename
  1100. CrystalReport1.DataFiles(0) = sRptDataFile
  1101. End Sub
  1102. Private Sub DirList_Change()
  1103. FileList.Path = DirList.Path
  1104. End Sub
  1105. Private Sub DriveList_Change()
  1106. DirList.Path = DriveList.Drive
  1107. End Sub
  1108. Private Sub FileList_DblClick()
  1109. ' Sets a variable for the report filename, which requires both the path
  1110. ' and file name to qualify
  1111. Dim sReportFile As String
  1112. sReportFile = FileList.Path & "\" & FileList.filename
  1113. CrystalReport1.ReportFileName = sReportFile
  1114. ResetIndexes
  1115. Timer1.Interval = 2000    ' wait 2 seconds before enabaling all other tabs,
  1116. With MainTab              ' and then automatically go to the next tab.
  1117.     .TabEnabled(1) = True
  1118.     .TabEnabled(2) = True
  1119.     .TabEnabled(3) = True
  1120.     .TabEnabled(4) = True
  1121. End With
  1122. OptWindow.SetFocus
  1123. CmdNext.Enabled = True
  1124. CmdBack.Enabled = True
  1125. CmdAccept.Enabled = True
  1126. CmdCancel.Caption = "Close"
  1127. MainTab.Tab = 1
  1128. End Sub
  1129. Private Sub Form_Load()
  1130. Center Me                             ' Centers the form onto the screen.
  1131. MainTab.Tab = 0                       ' Intialize the program with the first tab open.
  1132. CmdBack.Enabled = False               ' Disable the << Back button so that the user
  1133. CmdNext.Enabled = False               ' is not able to click and try to go back from the
  1134. CmdAccept.Enabled = False             ' first tab. The Next >> button is disabled so that the
  1135.                                       ' user cannot proceed without choosing a report first.
  1136.                                       ' The Accept button is disabled as there is nothing to
  1137.                                       ' accept at this point.
  1138.                                       
  1139. With MainTab                          ' Disable all tabs other than the first tab
  1140.     .TabEnabled(1) = False            ' (Open a Crystal Report) and the last tab
  1141.     .TabEnabled(2) = False            ' (About Crystal Reports)
  1142.     .TabEnabled(3) = False
  1143. End With
  1144. FrmWin.Enabled = False                ' Disable the frames that encapsulate the destination
  1145. FrmPrinter.Enabled = False            ' options for the window, printer, or file.
  1146. FrmFile.Enabled = False
  1147. End Sub
  1148. Private Sub FormulaTab_Click(PreviousTab As Integer)
  1149. If FormulaTab.Tab = 3 Then
  1150.     CmdAccptFormula.Enabled = False
  1151.     CmdClrFormula.Enabled = False
  1152.     CmdAccptFormula.Enabled = True
  1153.     CmdClrFormula.Enabled = True
  1154. End If
  1155. End Sub
  1156. Private Sub MainTab_Click(PreviousTab As Integer)
  1157.     'Dim iMainTabNum As Integer
  1158. '    Select Case iMainTabNum
  1159.  '   Case 0
  1160.   '  Case 1
  1161.    ' Case 2
  1162.    ' Case 3
  1163.     '    TxtFormulaName.SetFocus
  1164.         
  1165.    ' Case 4
  1166.    ' Case 5
  1167.     'End Select
  1168.      
  1169. End Sub
  1170. Private Sub OptCSV_Click()
  1171.     TxtPrnFileName.Text = ".csv"
  1172.     CrystalReport1.PrintFileType = 4
  1173.     TxtPrnFileName.SetFocus
  1174. End Sub
  1175. Private Sub OptDIF_Click()
  1176.     TxtPrnFileName.Text = ".dif"
  1177.     CrystalReport1.PrintFileType = 3
  1178.     TxtPrnFileName.SetFocus
  1179. End Sub
  1180. Private Sub OptFile_Click()
  1181. CrystalReport1.Destination = 2
  1182. FrmFile.Enabled = True
  1183. LblFileName.Enabled = True
  1184. OptCSV.Enabled = True
  1185. OptDIF.Enabled = True
  1186. OptRecord.Enabled = True
  1187. OptTabSep.Enabled = True
  1188. OptTabSepText.Enabled = True
  1189. OptText.Enabled = True
  1190. FrmFileType.Enabled = True
  1191. PrnFileDir.Enabled = True
  1192. PrnFileDrive.Enabled = True
  1193. TxtWinTitle.Text = " "
  1194. TxtPrnCopies.Text = " "
  1195. FrmWin.Enabled = False
  1196. LblWinTitle.Enabled = False
  1197. FrmPrinter.Enabled = False
  1198. LblPrnCopies.Enabled = False
  1199. SpinButton1.Enabled = False
  1200. SpinButton1.ForeColor = &HC0C0C0
  1201. End Sub
  1202. Private Sub OptPrinter_Click()
  1203. CrystalReport1.Destination = 1
  1204. FrmPrinter.Enabled = True
  1205. LblPrnCopies.Enabled = True
  1206. SpinButton1.Enabled = True
  1207. SpinButton1.ForeColor = &H0
  1208. TxtPrnCopies.SetFocus
  1209. TxtWinTitle.Text = " "
  1210. TxtPrnFileName.Text = " "
  1211. FrmWin.Enabled = False
  1212. LblWinTitle.Enabled = False
  1213. FrmFile.Enabled = False
  1214. LblFileName.Enabled = False
  1215. OptCSV.Enabled = False
  1216. OptDIF.Enabled = False
  1217. OptRecord.Enabled = False
  1218. OptTabSep.Enabled = False
  1219. OptTabSepText.Enabled = False
  1220. OptText.Enabled = False
  1221. FrmFileType.Enabled = False
  1222. PrnFileDir.Enabled = False
  1223. PrnFileDrive.Enabled = False
  1224. End Sub
  1225. Private Sub OptRecord_Click()
  1226.     TxtPrnFileName.Text = ".rec"
  1227.     CrystalReport1.PrintFileType = 0
  1228.     TxtPrnFileName.SetFocus
  1229. End Sub
  1230. Private Sub OptTabSep_Click()
  1231.     TxtPrnFileName.Text = ".tsv"
  1232.     CrystalReport1.PrintFileType = 1
  1233.     TxtPrnFileName.SetFocus
  1234. End Sub
  1235. Private Sub OptTabSepText_Click()
  1236.     TxtPrnFileName.Text = ".ttx"
  1237.     CrystalReport1.PrintFileType = 6
  1238.     TxtPrnFileName.SetFocus
  1239. End Sub
  1240. Private Sub OptText_Click()
  1241.     TxtPrnFileName.Text = ".txt"
  1242.     CrystalReport1.PrintFileType = 2
  1243.     TxtPrnFileName.SetFocus
  1244. End Sub
  1245. Private Sub OptWindow_Click()
  1246. CrystalReport1.Destination = 0
  1247. FrmWin.Enabled = True
  1248. LblWinTitle.Enabled = True
  1249. TxtWinTitle.SetFocus
  1250. TxtPrnCopies.Text = " "
  1251. TxtPrnFileName.Text = " "
  1252. FrmPrinter.Enabled = False
  1253. LblPrnCopies.Enabled = False
  1254. SpinButton1.Enabled = False
  1255. SpinButton1.ForeColor = &HC0C0C0
  1256. FrmFile.Enabled = False
  1257. LblFileName.Enabled = False
  1258. OptCSV.Enabled = False
  1259. OptDIF.Enabled = False
  1260. OptRecord.Enabled = False
  1261. OptTabSep.Enabled = False
  1262. OptTabSepText.Enabled = False
  1263. OptText.Enabled = False
  1264. FrmFileType.Enabled = False
  1265. PrnFileDir.Enabled = False
  1266. PrnFileDrive.Enabled = False
  1267. End Sub
  1268. Private Sub PrnFileDrive_Change()
  1269.     PrnFileDir.Path = PrnFileDrive.Drive
  1270. End Sub
  1271. Private Sub SpinButton1_SpinDown()
  1272. ' Decrement the value in the text box on every SpinDown event.
  1273. If Str$(Val(TxtPrnCopies.Text)) > 1 Then
  1274.     TxtPrnCopies.Text = Str$(Val(TxtPrnCopies.Text) - 1)
  1275.         ' Display the current value in the text box.
  1276.     TxtPrnCopies.Refresh
  1277.  Else
  1278.     TxtPrnCopies.Text = 1
  1279.         
  1280.  End If
  1281. End Sub
  1282. Private Sub SpinButton1_SpinUp()
  1283.     ' Increment the value in the text box on every SpinUp event.
  1284.     TxtPrnCopies.Text = Str$(Val(TxtPrnCopies.Text) + 1)
  1285.     ' Display the current value in the text box.
  1286.     TxtPrnCopies.Refresh
  1287. End Sub
  1288. Private Sub TxtFormulaName_Change()
  1289. CmdAccptFormula.Enabled = True
  1290. End Sub
  1291. Private Sub TxtGrpSelFormula_Change()
  1292. CmdAccptFormula.Enabled = True
  1293. End Sub
  1294. Private Sub TxtPrnCopies_KeyPress(KeyAscii As Integer)
  1295. If KeyAscii = 13 Then
  1296.     KeyAscii = 0
  1297.     CrystalReport1.Action = 1
  1298. End If
  1299. End Sub
  1300. Private Sub TxtPrnFileName_Change()
  1301.     Dim sPrintFile As String
  1302.     sPrintFile = PrnFileDir.Path & "\" & TxtPrnFileName.Text
  1303.     CrystalReport1.PrintFileName = sPrintFile
  1304. End Sub
  1305. Private Sub TxtPrnFileName_KeyPress(KeyAscii As Integer)
  1306. If KeyAscii = 13 Then
  1307.     KeyAscii = 0
  1308.     CrystalReport1.Action = 1
  1309. End If
  1310. End Sub
  1311. Private Sub TxtRecSelFormula_Change()
  1312. CmdAccptFormula.Enabled = True
  1313. End Sub
  1314. Private Sub TxtUserName_Change()
  1315. CmdSecurity.Enabled = True
  1316. End Sub
  1317. Private Sub TxtWinTitle_Change()
  1318. CrystalReport1.WindowTitle = TxtWinTitle.Text
  1319. End Sub
  1320. Private Sub TxtWinTitle_KeyPress(KeyAscii As Integer)
  1321. If KeyAscii = 13 Then
  1322.     CmdAccept_Click
  1323.     KeyAscii = 0
  1324. End If
  1325. End Sub
  1326. Public Sub ResetIndexes()
  1327. FormulaNum = 0
  1328. RecSort = 0
  1329. grpsort = 0
  1330. End Sub
  1331.