home *** CD-ROM | disk | FTP | other *** search
/ Chip 2001 Special / chip-cd_2001_spec_05.zip / spec_05 / apps / crystal / disk18 / Xvb371._ / Xvb371.
Text File  |  1999-08-23  |  22KB  |  714 lines

  1. VERSION 5.00
  2. Begin VB.Form frmFinancials 
  3.    BorderStyle     =   3  'Fixed Dialog
  4.    Caption         =   "Financials"
  5.    ClientHeight    =   5385
  6.    ClientLeft      =   345
  7.    ClientTop       =   840
  8.    ClientWidth     =   8010
  9.    LinkTopic       =   "Form1"
  10.    MaxButton       =   0   'False
  11.    MinButton       =   0   'False
  12.    ScaleHeight     =   5385
  13.    ScaleWidth      =   8010
  14.    ShowInTaskbar   =   0   'False
  15.    Tag             =   "Financials"
  16.    Begin VB.CommandButton cmdClose 
  17.       Cancel          =   -1  'True
  18.       Caption         =   "&Close"
  19.       Default         =   -1  'True
  20.       Height          =   300
  21.       Left            =   5520
  22.       TabIndex        =   57
  23.       Top             =   4635
  24.       Width           =   975
  25.    End
  26.    Begin VB.CommandButton cmdGrid 
  27.       Caption         =   "&Grid"
  28.       Height          =   300
  29.       Left            =   4440
  30.       TabIndex        =   56
  31.       Tag             =   "&Grid"
  32.       Top             =   4635
  33.       Width           =   975
  34.    End
  35.    Begin VB.CommandButton cmdUpdate 
  36.       Caption         =   "&Update"
  37.       Height          =   300
  38.       Left            =   3360
  39.       TabIndex        =   55
  40.       Tag             =   "&Update"
  41.       Top             =   4635
  42.       Width           =   975
  43.    End
  44.    Begin VB.CommandButton cmdRefresh 
  45.       Caption         =   "&Refresh"
  46.       Height          =   300
  47.       Left            =   2280
  48.       TabIndex        =   54
  49.       Tag             =   "&Refresh"
  50.       Top             =   4635
  51.       Width           =   975
  52.    End
  53.    Begin VB.CommandButton cmdDelete 
  54.       Caption         =   "&Delete"
  55.       Height          =   300
  56.       Left            =   1200
  57.       TabIndex        =   53
  58.       Tag             =   "&Delete"
  59.       Top             =   4635
  60.       Width           =   975
  61.    End
  62.    Begin VB.CommandButton cmdAdd 
  63.       Caption         =   "&Add"
  64.       Height          =   300
  65.       Left            =   120
  66.       TabIndex        =   52
  67.       Tag             =   "&Add"
  68.       Top             =   4635
  69.       Width           =   975
  70.    End
  71.    Begin VB.Data Data1 
  72.       Align           =   2  'Align Bottom
  73.       Connect         =   "Access"
  74.       DatabaseName    =   ""
  75.       DefaultCursorType=   0  'DefaultCursor
  76.       DefaultType     =   2  'UseODBC
  77.       Exclusive       =   0   'False
  78.       Height          =   345
  79.       Left            =   0
  80.       Options         =   0
  81.       ReadOnly        =   0   'False
  82.       RecordsetType   =   1  'Dynaset
  83.       RecordSource    =   "Financials"
  84.       Top             =   5040
  85.       Width           =   8010
  86.    End
  87.    Begin VB.TextBox txtFields 
  88.       DataField       =   "Taxes"
  89.       DataSource      =   "Data1"
  90.       Height          =   285
  91.       Index           =   25
  92.       Left            =   5985
  93.       TabIndex        =   51
  94.       Top             =   3870
  95.       Width           =   1935
  96.    End
  97.    Begin VB.TextBox txtFields 
  98.       DataField       =   "Other Income Expenses"
  99.       DataSource      =   "Data1"
  100.       Height          =   285
  101.       Index           =   24
  102.       Left            =   5985
  103.       TabIndex        =   49
  104.       Top             =   3555
  105.       Width           =   1935
  106.    End
  107.    Begin VB.TextBox txtFields 
  108.       DataField       =   "Interest Expenses"
  109.       DataSource      =   "Data1"
  110.       Height          =   285
  111.       Index           =   23
  112.       Left            =   5985
  113.       TabIndex        =   47
  114.       Top             =   3225
  115.       Width           =   1935
  116.    End
  117.    Begin VB.TextBox txtFields 
  118.       DataField       =   "Depreciation"
  119.       DataSource      =   "Data1"
  120.       Height          =   285
  121.       Index           =   22
  122.       Left            =   5985
  123.       TabIndex        =   45
  124.       Top             =   2910
  125.       Width           =   1935
  126.    End
  127.    Begin VB.TextBox txtFields 
  128.       DataField       =   "Selling/Admin/ General Expenses"
  129.       DataSource      =   "Data1"
  130.       Height          =   285
  131.       Index           =   21
  132.       Left            =   5985
  133.       TabIndex        =   43
  134.       Top             =   2595
  135.       Width           =   1935
  136.    End
  137.    Begin VB.TextBox txtFields 
  138.       DataField       =   "COGS"
  139.       DataSource      =   "Data1"
  140.       Height          =   285
  141.       Index           =   20
  142.       Left            =   5985
  143.       TabIndex        =   41
  144.       Top             =   2265
  145.       Width           =   1935
  146.    End
  147.    Begin VB.TextBox txtFields 
  148.       DataField       =   "Net Sales"
  149.       DataSource      =   "Data1"
  150.       Height          =   285
  151.       Index           =   19
  152.       Left            =   5985
  153.       TabIndex        =   39
  154.       Top             =   1950
  155.       Width           =   1935
  156.    End
  157.    Begin VB.TextBox txtFields 
  158.       DataField       =   "Retained Earnings"
  159.       DataSource      =   "Data1"
  160.       Height          =   285
  161.       Index           =   18
  162.       Left            =   5985
  163.       TabIndex        =   37
  164.       Top             =   1635
  165.       Width           =   1935
  166.    End
  167.    Begin VB.TextBox txtFields 
  168.       DataField       =   "Common Stock"
  169.       DataSource      =   "Data1"
  170.       Height          =   285
  171.       Index           =   17
  172.       Left            =   5985
  173.       TabIndex        =   35
  174.       Top             =   1305
  175.       Width           =   1935
  176.    End
  177.    Begin VB.TextBox txtFields 
  178.       DataField       =   "Preferred Stock"
  179.       DataSource      =   "Data1"
  180.       Height          =   285
  181.       Index           =   16
  182.       Left            =   5985
  183.       TabIndex        =   33
  184.       Top             =   990
  185.       Width           =   1935
  186.    End
  187.    Begin VB.TextBox txtFields 
  188.       DataField       =   "Deferred Income Taxes"
  189.       DataSource      =   "Data1"
  190.       Height          =   285
  191.       Index           =   15
  192.       Left            =   5985
  193.       TabIndex        =   31
  194.       Top             =   675
  195.       Width           =   1935
  196.    End
  197.    Begin VB.TextBox txtFields 
  198.       DataField       =   "Notes Payable"
  199.       DataSource      =   "Data1"
  200.       Height          =   285
  201.       Index           =   14
  202.       Left            =   5985
  203.       TabIndex        =   29
  204.       Top             =   345
  205.       Width           =   1935
  206.    End
  207.    Begin VB.TextBox txtFields 
  208.       DataField       =   "Accrued Income Taxes"
  209.       DataSource      =   "Data1"
  210.       Height          =   285
  211.       Index           =   13
  212.       Left            =   2040
  213.       TabIndex        =   27
  214.       Top             =   4200
  215.       Width           =   1935
  216.    End
  217.    Begin VB.TextBox txtFields 
  218.       DataField       =   "Accrued Liabilities"
  219.       DataSource      =   "Data1"
  220.       Height          =   285
  221.       Index           =   12
  222.       Left            =   2040
  223.       TabIndex        =   25
  224.       Top             =   3880
  225.       Width           =   1935
  226.    End
  227.    Begin VB.TextBox txtFields 
  228.       DataField       =   "Accounts Payable"
  229.       DataSource      =   "Data1"
  230.       Height          =   285
  231.       Index           =   11
  232.       Left            =   2040
  233.       TabIndex        =   23
  234.       Top             =   3560
  235.       Width           =   1935
  236.    End
  237.    Begin VB.TextBox txtFields 
  238.       DataField       =   "Other Assets"
  239.       DataSource      =   "Data1"
  240.       Height          =   285
  241.       Index           =   10
  242.       Left            =   2040
  243.       TabIndex        =   21
  244.       Top             =   3240
  245.       Width           =   1935
  246.    End
  247.    Begin VB.TextBox txtFields 
  248.       DataField       =   "Accumulated Depreciation"
  249.       DataSource      =   "Data1"
  250.       Height          =   285
  251.       Index           =   9
  252.       Left            =   2040
  253.       TabIndex        =   19
  254.       Top             =   2920
  255.       Width           =   1935
  256.    End
  257.    Begin VB.TextBox txtFields 
  258.       DataField       =   "Machinery etc"
  259.       DataSource      =   "Data1"
  260.       Height          =   285
  261.       Index           =   8
  262.       Left            =   2040
  263.       TabIndex        =   17
  264.       Top             =   2600
  265.       Width           =   1935
  266.    End
  267.    Begin VB.TextBox txtFields 
  268.       DataField       =   "Buildings"
  269.       DataSource      =   "Data1"
  270.       Height          =   285
  271.       Index           =   7
  272.       Left            =   2040
  273.       TabIndex        =   15
  274.       Top             =   2280
  275.       Width           =   1935
  276.    End
  277.    Begin VB.TextBox txtFields 
  278.       DataField       =   "Land"
  279.       DataSource      =   "Data1"
  280.       Height          =   285
  281.       Index           =   6
  282.       Left            =   2040
  283.       TabIndex        =   13
  284.       Top             =   1960
  285.       Width           =   1935
  286.    End
  287.    Begin VB.TextBox txtFields 
  288.       DataField       =   "Other Current Assets"
  289.       DataSource      =   "Data1"
  290.       Height          =   285
  291.       Index           =   5
  292.       Left            =   2040
  293.       TabIndex        =   11
  294.       Top             =   1640
  295.       Width           =   1935
  296.    End
  297.    Begin VB.TextBox txtFields 
  298.       DataField       =   "Inventories"
  299.       DataSource      =   "Data1"
  300.       Height          =   285
  301.       Index           =   4
  302.       Left            =   2040
  303.       TabIndex        =   9
  304.       Top             =   1320
  305.       Width           =   1935
  306.    End
  307.    Begin VB.TextBox txtFields 
  308.       DataField       =   "Account Receivable"
  309.       DataSource      =   "Data1"
  310.       Height          =   285
  311.       Index           =   3
  312.       Left            =   2040
  313.       TabIndex        =   7
  314.       Top             =   1000
  315.       Width           =   1935
  316.    End
  317.    Begin VB.TextBox txtFields 
  318.       DataField       =   "Cash"
  319.       DataSource      =   "Data1"
  320.       Height          =   285
  321.       Index           =   2
  322.       Left            =   2040
  323.       TabIndex        =   5
  324.       Top             =   680
  325.       Width           =   1935
  326.    End
  327.    Begin VB.TextBox txtFields 
  328.       DataField       =   "Statement Date"
  329.       DataSource      =   "Data1"
  330.       Height          =   285
  331.       Index           =   1
  332.       Left            =   2040
  333.       TabIndex        =   3
  334.       Top             =   360
  335.       Width           =   1935
  336.    End
  337.    Begin VB.TextBox txtFields 
  338.       DataField       =   "Company ID"
  339.       DataSource      =   "Data1"
  340.       Height          =   285
  341.       Index           =   0
  342.       Left            =   2040
  343.       MaxLength       =   5
  344.       TabIndex        =   1
  345.       Top             =   40
  346.       Width           =   3375
  347.    End
  348.    Begin VB.Label lblLabels 
  349.       Caption         =   "Taxes:"
  350.       Height          =   255
  351.       Index           =   25
  352.       Left            =   4065
  353.       TabIndex        =   50
  354.       Tag             =   "Taxes:"
  355.       Top             =   3885
  356.       Width           =   1815
  357.    End
  358.    Begin VB.Label lblLabels 
  359.       Caption         =   "Other Income Expenses:"
  360.       Height          =   255
  361.       Index           =   24
  362.       Left            =   4065
  363.       TabIndex        =   48
  364.       Tag             =   "Other Income Expenses:"
  365.       Top             =   3570
  366.       Width           =   1815
  367.    End
  368.    Begin VB.Label lblLabels 
  369.       Caption         =   "Interest Expenses:"
  370.       Height          =   255
  371.       Index           =   23
  372.       Left            =   4065
  373.       TabIndex        =   46
  374.       Tag             =   "Interest Expenses:"
  375.       Top             =   3255
  376.       Width           =   1815
  377.    End
  378.    Begin VB.Label lblLabels 
  379.       Caption         =   "Depreciation:"
  380.       Height          =   255
  381.       Index           =   22
  382.       Left            =   4065
  383.       TabIndex        =   44
  384.       Tag             =   "Depreciation:"
  385.       Top             =   2925
  386.       Width           =   1815
  387.    End
  388.    Begin VB.Label lblLabels 
  389.       Caption         =   "Selling/Admin/ General Expenses:"
  390.       Height          =   255
  391.       Index           =   21
  392.       Left            =   4065
  393.       TabIndex        =   42
  394.       Tag             =   "Selling/Admin/ General Expenses:"
  395.       Top             =   2610
  396.       Width           =   1815
  397.    End
  398.    Begin VB.Label lblLabels 
  399.       Caption         =   "COGS:"
  400.       Height          =   255
  401.       Index           =   20
  402.       Left            =   4065
  403.       TabIndex        =   40
  404.       Tag             =   "COGS:"
  405.       Top             =   2295
  406.       Width           =   1815
  407.    End
  408.    Begin VB.Label lblLabels 
  409.       Caption         =   "Net Sales:"
  410.       Height          =   255
  411.       Index           =   19
  412.       Left            =   4065
  413.       TabIndex        =   38
  414.       Tag             =   "Net Sales:"
  415.       Top             =   1965
  416.       Width           =   1815
  417.    End
  418.    Begin VB.Label lblLabels 
  419.       Caption         =   "Retained Earnings:"
  420.       Height          =   255
  421.       Index           =   18
  422.       Left            =   4065
  423.       TabIndex        =   36
  424.       Tag             =   "Retained Earnings:"
  425.       Top             =   1650
  426.       Width           =   1815
  427.    End
  428.    Begin VB.Label lblLabels 
  429.       Caption         =   "Common Stock:"
  430.       Height          =   255
  431.       Index           =   17
  432.       Left            =   4065
  433.       TabIndex        =   34
  434.       Tag             =   "Common Stock:"
  435.       Top             =   1335
  436.       Width           =   1815
  437.    End
  438.    Begin VB.Label lblLabels 
  439.       Caption         =   "Preferred Stock:"
  440.       Height          =   255
  441.       Index           =   16
  442.       Left            =   4065
  443.       TabIndex        =   32
  444.       Tag             =   "Preferred Stock:"
  445.       Top             =   1005
  446.       Width           =   1815
  447.    End
  448.    Begin VB.Label lblLabels 
  449.       Caption         =   "Deferred Income Taxes:"
  450.       Height          =   255
  451.       Index           =   15
  452.       Left            =   4065
  453.       TabIndex        =   30
  454.       Tag             =   "Deferred Income Taxes:"
  455.       Top             =   690
  456.       Width           =   1815
  457.    End
  458.    Begin VB.Label lblLabels 
  459.       Caption         =   "Notes Payable:"
  460.       Height          =   255
  461.       Index           =   14
  462.       Left            =   4065
  463.       TabIndex        =   28
  464.       Tag             =   "Notes Payable:"
  465.       Top             =   375
  466.       Width           =   1815
  467.    End
  468.    Begin VB.Label lblLabels 
  469.       Caption         =   "Accrued Income Taxes:"
  470.       Height          =   255
  471.       Index           =   13
  472.       Left            =   120
  473.       TabIndex        =   26
  474.       Tag             =   "Accrued Income Taxes:"
  475.       Top             =   4220
  476.       Width           =   1815
  477.    End
  478.    Begin VB.Label lblLabels 
  479.       Caption         =   "Accrued Liabilities:"
  480.       Height          =   255
  481.       Index           =   12
  482.       Left            =   120
  483.       TabIndex        =   24
  484.       Tag             =   "Accrued Liabilities:"
  485.       Top             =   3900
  486.       Width           =   1815
  487.    End
  488.    Begin VB.Label lblLabels 
  489.       Caption         =   "Accounts Payable:"
  490.       Height          =   255
  491.       Index           =   11
  492.       Left            =   120
  493.       TabIndex        =   22
  494.       Tag             =   "Accounts Payable:"
  495.       Top             =   3580
  496.       Width           =   1815
  497.    End
  498.    Begin VB.Label lblLabels 
  499.       Caption         =   "Other Assets:"
  500.       Height          =   255
  501.       Index           =   10
  502.       Left            =   120
  503.       TabIndex        =   20
  504.       Tag             =   "Other Assets:"
  505.       Top             =   3260
  506.       Width           =   1815
  507.    End
  508.    Begin VB.Label lblLabels 
  509.       Caption         =   "Accumulated Depreciation:"
  510.       Height          =   255
  511.       Index           =   9
  512.       Left            =   120
  513.       TabIndex        =   18
  514.       Tag             =   "Accumulated Depreciation:"
  515.       Top             =   2940
  516.       Width           =   1815
  517.    End
  518.    Begin VB.Label lblLabels 
  519.       Caption         =   "Machinery etc:"
  520.       Height          =   255
  521.       Index           =   8
  522.       Left            =   120
  523.       TabIndex        =   16
  524.       Tag             =   "Machinery etc:"
  525.       Top             =   2620
  526.       Width           =   1815
  527.    End
  528.    Begin VB.Label lblLabels 
  529.       Caption         =   "Buildings:"
  530.       Height          =   255
  531.       Index           =   7
  532.       Left            =   120
  533.       TabIndex        =   14
  534.       Tag             =   "Buildings:"
  535.       Top             =   2300
  536.       Width           =   1815
  537.    End
  538.    Begin VB.Label lblLabels 
  539.       Caption         =   "Land:"
  540.       Height          =   255
  541.       Index           =   6
  542.       Left            =   120
  543.       TabIndex        =   12
  544.       Tag             =   "Land:"
  545.       Top             =   1980
  546.       Width           =   1815
  547.    End
  548.    Begin VB.Label lblLabels 
  549.       Caption         =   "Other Current Assets:"
  550.       Height          =   255
  551.       Index           =   5
  552.       Left            =   120
  553.       TabIndex        =   10
  554.       Tag             =   "Other Current Assets:"
  555.       Top             =   1660
  556.       Width           =   1815
  557.    End
  558.    Begin VB.Label lblLabels 
  559.       Caption         =   "Inventories:"
  560.       Height          =   255
  561.       Index           =   4
  562.       Left            =   120
  563.       TabIndex        =   8
  564.       Tag             =   "Inventories:"
  565.       Top             =   1340
  566.       Width           =   1815
  567.    End
  568.    Begin VB.Label lblLabels 
  569.       Caption         =   "Account Receivable:"
  570.       Height          =   255
  571.       Index           =   3
  572.       Left            =   120
  573.       TabIndex        =   6
  574.       Tag             =   "Account Receivable:"
  575.       Top             =   1020
  576.       Width           =   1815
  577.    End
  578.    Begin VB.Label lblLabels 
  579.       Caption         =   "Cash:"
  580.       Height          =   255
  581.       Index           =   2
  582.       Left            =   120
  583.       TabIndex        =   4
  584.       Tag             =   "Cash:"
  585.       Top             =   700
  586.       Width           =   1815
  587.    End
  588.    Begin VB.Label lblLabels 
  589.       Caption         =   "Statement Date:"
  590.       Height          =   255
  591.       Index           =   1
  592.       Left            =   120
  593.       TabIndex        =   2
  594.       Tag             =   "Statement Date:"
  595.       Top             =   380
  596.       Width           =   1815
  597.    End
  598.    Begin VB.Label lblLabels 
  599.       Caption         =   "Company ID:"
  600.       Height          =   255
  601.       Index           =   0
  602.       Left            =   120
  603.       TabIndex        =   0
  604.       Tag             =   "Company ID:"
  605.       Top             =   60
  606.       Width           =   1815
  607.    End
  608. End
  609. Attribute VB_Name = "frmFinancials"
  610. Attribute VB_GlobalNameSpace = False
  611. Attribute VB_Creatable = False
  612. Attribute VB_PredeclaredId = True
  613. Attribute VB_Exposed = False
  614. Option Explicit
  615.  
  616. Private Sub cmdAdd_Click()
  617.     Data1.Recordset.AddNew
  618. End Sub
  619.  
  620.  
  621. Private Sub cmdClose_Click()
  622.   Me.Hide
  623. End Sub
  624.  
  625. Private Sub cmdDelete_Click()
  626.     'this may produce an error if you delete the last
  627.     'record or the only record in the recordset
  628.     With Data1.Recordset
  629.         .Delete
  630.         .MoveNext
  631.         If .EOF Then .MoveLast
  632.     End With
  633. End Sub
  634.  
  635.  
  636. Private Sub cmdRefresh_Click()
  637.     'this is really only needed for multi user apps
  638.     Data1.Refresh
  639. End Sub
  640.  
  641.  
  642. Private Sub cmdUpdate_Click()
  643.     Data1.UpdateRecord
  644.     Data1.Recordset.Bookmark = Data1.Recordset.LastModified
  645. End Sub
  646.  
  647.  
  648. Private Sub cmdGrid_Click()
  649.     On Error GoTo cmdGrid_ClickErr
  650.  
  651.  
  652.     Dim f As New frmDataGrid
  653.     Set f.Data1.Recordset = Data1.Recordset
  654.     f.Caption = Me.Caption & " Grid"
  655.     f.Show
  656.  
  657.  
  658.     Exit Sub
  659. cmdGrid_ClickErr:
  660. End Sub
  661.  
  662.  
  663. Private Sub Data1_Error(DataErr As Integer, Response As Integer)
  664.     'This is where you would put error handling code
  665.     'If you want to ignore errors, comment out the next line
  666.     'If you want to trap them, add code here to handle them
  667.     MsgBox "Data error event hit err:" & Error$(DataErr)
  668.     Response = 0  'throw away the error
  669. End Sub
  670.  
  671.  
  672. Private Sub Data1_Reposition()
  673.     Screen.MousePointer = vbDefault
  674.     On Error Resume Next
  675.     'This will display the current record position
  676.     'for dynasets and snapshots
  677.     Data1.Caption = "Record: " & (Data1.Recordset.AbsolutePosition + 1)
  678.     'for the table object you must set the index property when
  679.     'the recordset gets created and use the following line
  680.     'Data1.Caption = "Record: " & (Data1.Recordset.RecordCount * (Data1.Recordset.PercentPosition * 0.01)) + 1
  681. End Sub
  682.  
  683.  
  684. Private Sub Data1_Validate(Action As Integer, Save As Integer)
  685.     'This is where you put validation code
  686.     'This event gets called when the following actions occur
  687.     Select Case Action
  688.         Case vbDataActionMoveFirst
  689.         Case vbDataActionMovePrevious
  690.         Case vbDataActionMoveNext
  691.         Case vbDataActionMoveLast
  692.         Case vbDataActionAddNew
  693.         Case vbDataActionUpdate
  694.         Case vbDataActionDelete
  695.         Case vbDataActionFind
  696.         Case vbDataActionBookmark
  697.         Case vbDataActionClose
  698.             Screen.MousePointer = vbDefault
  699.     End Select
  700.     Screen.MousePointer = vbHourglass
  701. End Sub
  702.  
  703. Private Sub Form_Load()
  704.   Center Me
  705.   Me.Data1.DatabaseName = frmMain.gsDatabase
  706. End Sub
  707.  
  708. Private Sub Form_Unload(Cancel As Integer)
  709.     Screen.MousePointer = vbDefault
  710. End Sub
  711.  
  712.  
  713.  
  714.