home *** CD-ROM | disk | FTP | other *** search
/ Planet Source Code Jumbo …e CD Visual Basic 1 to 7 / 4_2005-2006.ISO / data / Zips / customer_c189748652005.psc / complaints.frm < prev    next >
Text File  |  1995-03-04  |  72KB  |  2,071 lines

  1. VERSION 5.00
  2. Object = "{67397AA1-7FB1-11D0-B148-00A0C922E820}#6.0#0"; "MSADODC.OCX"
  3. Object = "{CDE57A40-8B86-11D0-B3C6-00A0C90AEA82}#1.0#0"; "MSDATGRD.OCX"
  4. Begin VB.Form complaintsfrm 
  5.    BackColor       =   &H00FFFFFF&
  6.    BorderStyle     =   1  'Fixed Single
  7.    Caption         =   "Complaint Form"
  8.    ClientHeight    =   11625
  9.    ClientLeft      =   45
  10.    ClientTop       =   345
  11.    ClientWidth     =   9480
  12.    FillStyle       =   0  'Solid
  13.    LinkTopic       =   "Form1"
  14.    LockControls    =   -1  'True
  15.    MaxButton       =   0   'False
  16.    MDIChild        =   -1  'True
  17.    MinButton       =   0   'False
  18.    Moveable        =   0   'False
  19.    ScaleHeight     =   11625
  20.    ScaleWidth      =   9480
  21.    Begin MSDataGridLib.DataGrid comp_grid 
  22.       Bindings        =   "complaints.frx":0000
  23.       Height          =   1215
  24.       Left            =   0
  25.       TabIndex        =   56
  26.       Top             =   8880
  27.       Width           =   9375
  28.       _ExtentX        =   16536
  29.       _ExtentY        =   2143
  30.       _Version        =   393216
  31.       AllowUpdate     =   0   'False
  32.       HeadLines       =   1
  33.       RowHeight       =   15
  34.       FormatLocked    =   -1  'True
  35.       BeginProperty HeadFont {0BE35203-8F91-11CE-9DE3-00AA004BB851} 
  36.          Name            =   "MS Sans Serif"
  37.          Size            =   8.25
  38.          Charset         =   0
  39.          Weight          =   400
  40.          Underline       =   0   'False
  41.          Italic          =   0   'False
  42.          Strikethrough   =   0   'False
  43.       EndProperty
  44.       BeginProperty Font {0BE35203-8F91-11CE-9DE3-00AA004BB851} 
  45.          Name            =   "MS Sans Serif"
  46.          Size            =   8.25
  47.          Charset         =   0
  48.          Weight          =   400
  49.          Underline       =   0   'False
  50.          Italic          =   0   'False
  51.          Strikethrough   =   0   'False
  52.       EndProperty
  53.       ColumnCount     =   11
  54.       BeginProperty Column00 
  55.          DataField       =   "comp_custph1"
  56.          Caption         =   "comp_custph1"
  57.          BeginProperty DataFormat {6D835690-900B-11D0-9484-00A0C91110ED} 
  58.             Type            =   0
  59.             Format          =   ""
  60.             HaveTrueFalseNull=   0
  61.             FirstDayOfWeek  =   0
  62.             FirstWeekOfYear =   0
  63.             LCID            =   1033
  64.             SubFormatType   =   0
  65.          EndProperty
  66.       EndProperty
  67.       BeginProperty Column01 
  68.          DataField       =   "comp_date"
  69.          Caption         =   "comp_date"
  70.          BeginProperty DataFormat {6D835690-900B-11D0-9484-00A0C91110ED} 
  71.             Type            =   0
  72.             Format          =   ""
  73.             HaveTrueFalseNull=   0
  74.             FirstDayOfWeek  =   0
  75.             FirstWeekOfYear =   0
  76.             LCID            =   1033
  77.             SubFormatType   =   0
  78.          EndProperty
  79.       EndProperty
  80.       BeginProperty Column02 
  81.          DataField       =   "comp_madeby"
  82.          Caption         =   "Complaint Made by"
  83.          BeginProperty DataFormat {6D835690-900B-11D0-9484-00A0C91110ED} 
  84.             Type            =   0
  85.             Format          =   ""
  86.             HaveTrueFalseNull=   0
  87.             FirstDayOfWeek  =   0
  88.             FirstWeekOfYear =   0
  89.             LCID            =   1033
  90.             SubFormatType   =   0
  91.          EndProperty
  92.       EndProperty
  93.       BeginProperty Column03 
  94.          DataField       =   "comp_prdicno"
  95.          Caption         =   "Inst. Card No"
  96.          BeginProperty DataFormat {6D835690-900B-11D0-9484-00A0C91110ED} 
  97.             Type            =   0
  98.             Format          =   ""
  99.             HaveTrueFalseNull=   0
  100.             FirstDayOfWeek  =   0
  101.             FirstWeekOfYear =   0
  102.             LCID            =   1033
  103.             SubFormatType   =   0
  104.          EndProperty
  105.       EndProperty
  106.       BeginProperty Column04 
  107.          DataField       =   "comp_desc"
  108.          Caption         =   "Complaint Description"
  109.          BeginProperty DataFormat {6D835690-900B-11D0-9484-00A0C91110ED} 
  110.             Type            =   0
  111.             Format          =   ""
  112.             HaveTrueFalseNull=   0
  113.             FirstDayOfWeek  =   0
  114.             FirstWeekOfYear =   0
  115.             LCID            =   1033
  116.             SubFormatType   =   0
  117.          EndProperty
  118.       EndProperty
  119.       BeginProperty Column05 
  120.          DataField       =   "comp_no"
  121.          Caption         =   "Complaint No"
  122.          BeginProperty DataFormat {6D835690-900B-11D0-9484-00A0C91110ED} 
  123.             Type            =   0
  124.             Format          =   ""
  125.             HaveTrueFalseNull=   0
  126.             FirstDayOfWeek  =   0
  127.             FirstWeekOfYear =   0
  128.             LCID            =   1033
  129.             SubFormatType   =   0
  130.          EndProperty
  131.       EndProperty
  132.       BeginProperty Column06 
  133.          DataField       =   "comp_status"
  134.          Caption         =   "Status"
  135.          BeginProperty DataFormat {6D835690-900B-11D0-9484-00A0C91110ED} 
  136.             Type            =   0
  137.             Format          =   ""
  138.             HaveTrueFalseNull=   0
  139.             FirstDayOfWeek  =   0
  140.             FirstWeekOfYear =   0
  141.             LCID            =   1033
  142.             SubFormatType   =   0
  143.          EndProperty
  144.       EndProperty
  145.       BeginProperty Column07 
  146.          DataField       =   "comp_attdate"
  147.          Caption         =   "Complaint Attd On"
  148.          BeginProperty DataFormat {6D835690-900B-11D0-9484-00A0C91110ED} 
  149.             Type            =   0
  150.             Format          =   ""
  151.             HaveTrueFalseNull=   0
  152.             FirstDayOfWeek  =   0
  153.             FirstWeekOfYear =   0
  154.             LCID            =   1033
  155.             SubFormatType   =   0
  156.          EndProperty
  157.       EndProperty
  158.       BeginProperty Column08 
  159.          DataField       =   "comp_attby"
  160.          Caption         =   "Complaint Attd. By"
  161.          BeginProperty DataFormat {6D835690-900B-11D0-9484-00A0C91110ED} 
  162.             Type            =   0
  163.             Format          =   ""
  164.             HaveTrueFalseNull=   0
  165.             FirstDayOfWeek  =   0
  166.             FirstWeekOfYear =   0
  167.             LCID            =   1033
  168.             SubFormatType   =   0
  169.          EndProperty
  170.       EndProperty
  171.       BeginProperty Column09 
  172.          DataField       =   "comp_cause"
  173.          Caption         =   "Complaint Cause"
  174.          BeginProperty DataFormat {6D835690-900B-11D0-9484-00A0C91110ED} 
  175.             Type            =   0
  176.             Format          =   ""
  177.             HaveTrueFalseNull=   0
  178.             FirstDayOfWeek  =   0
  179.             FirstWeekOfYear =   0
  180.             LCID            =   1033
  181.             SubFormatType   =   0
  182.          EndProperty
  183.       EndProperty
  184.       BeginProperty Column10 
  185.          DataField       =   "comp_action"
  186.          Caption         =   "Action Taken"
  187.          BeginProperty DataFormat {6D835690-900B-11D0-9484-00A0C91110ED} 
  188.             Type            =   0
  189.             Format          =   ""
  190.             HaveTrueFalseNull=   0
  191.             FirstDayOfWeek  =   0
  192.             FirstWeekOfYear =   0
  193.             LCID            =   1033
  194.             SubFormatType   =   0
  195.          EndProperty
  196.       EndProperty
  197.       SplitCount      =   1
  198.       BeginProperty Split0 
  199.          BeginProperty Column00 
  200.             ColumnWidth     =   14.74
  201.          EndProperty
  202.          BeginProperty Column01 
  203.             ColumnWidth     =   1200.189
  204.          EndProperty
  205.          BeginProperty Column02 
  206.             ColumnWidth     =   1739.906
  207.          EndProperty
  208.          BeginProperty Column03 
  209.             ColumnWidth     =   1154.835
  210.          EndProperty
  211.          BeginProperty Column04 
  212.             ColumnWidth     =   1860.095
  213.          EndProperty
  214.          BeginProperty Column05 
  215.             ColumnWidth     =   1184.882
  216.          EndProperty
  217.          BeginProperty Column06 
  218.             ColumnWidth     =   1500.095
  219.          EndProperty
  220.          BeginProperty Column07 
  221.             ColumnWidth     =   1395.213
  222.          EndProperty
  223.          BeginProperty Column08 
  224.             ColumnWidth     =   1800
  225.          EndProperty
  226.          BeginProperty Column09 
  227.             ColumnWidth     =   3390.236
  228.          EndProperty
  229.          BeginProperty Column10 
  230.             ColumnWidth     =   1904.882
  231.          EndProperty
  232.       EndProperty
  233.    End
  234.    Begin MSAdodcLib.Adodc comp_data 
  235.       Height          =   330
  236.       Left            =   7560
  237.       Top             =   2040
  238.       Visible         =   0   'False
  239.       Width           =   1215
  240.       _ExtentX        =   2143
  241.       _ExtentY        =   582
  242.       ConnectMode     =   0
  243.       CursorLocation  =   3
  244.       IsolationLevel  =   -1
  245.       ConnectionTimeout=   15
  246.       CommandTimeout  =   30
  247.       CursorType      =   3
  248.       LockType        =   3
  249.       CommandType     =   2
  250.       CursorOptions   =   0
  251.       CacheSize       =   50
  252.       MaxRecords      =   0
  253.       BOFAction       =   0
  254.       EOFAction       =   0
  255.       ConnectStringType=   1
  256.       Appearance      =   1
  257.       BackColor       =   -2147483643
  258.       ForeColor       =   -2147483640
  259.       Orientation     =   0
  260.       Enabled         =   -1
  261.       Connect         =   "Provider=Microsoft.Jet.OLEDB.4.0;Data Source=c:\program files\custcareprj\custcaredb.mdb;Persist Security Info=False"
  262.       OLEDBString     =   "Provider=Microsoft.Jet.OLEDB.4.0;Data Source=c:\program files\custcareprj\custcaredb.mdb;Persist Security Info=False"
  263.       OLEDBFile       =   ""
  264.       DataSourceName  =   ""
  265.       OtherAttributes =   ""
  266.       UserName        =   ""
  267.       Password        =   ""
  268.       RecordSource    =   "complaintstemp"
  269.       Caption         =   "Adodc1"
  270.       BeginProperty Font {0BE35203-8F91-11CE-9DE3-00AA004BB851} 
  271.          Name            =   "MS Sans Serif"
  272.          Size            =   8.25
  273.          Charset         =   0
  274.          Weight          =   400
  275.          Underline       =   0   'False
  276.          Italic          =   0   'False
  277.          Strikethrough   =   0   'False
  278.       EndProperty
  279.       _Version        =   393216
  280.    End
  281.    Begin VB.ListBox comp_prodinfo 
  282.       BeginProperty Font 
  283.          Name            =   "Verdana"
  284.          Size            =   8.25
  285.          Charset         =   0
  286.          Weight          =   400
  287.          Underline       =   0   'False
  288.          Italic          =   0   'False
  289.          Strikethrough   =   0   'False
  290.       EndProperty
  291.       Height          =   1035
  292.       Left            =   5400
  293.       TabIndex        =   55
  294.       Top             =   4620
  295.       Visible         =   0   'False
  296.       Width           =   3855
  297.    End
  298.    Begin VB.CommandButton Show_grid 
  299.       Caption         =   "Show All &Complaints"
  300.       BeginProperty Font 
  301.          Name            =   "Verdana"
  302.          Size            =   8.25
  303.          Charset         =   0
  304.          Weight          =   400
  305.          Underline       =   0   'False
  306.          Italic          =   0   'False
  307.          Strikethrough   =   0   'False
  308.       EndProperty
  309.       Height          =   375
  310.       Left            =   60
  311.       TabIndex        =   47
  312.       Top             =   8310
  313.       Width           =   1905
  314.    End
  315.    Begin VB.Frame Frame2 
  316.       BackColor       =   &H00FFFFFF&
  317.       Caption         =   "Customer Details:"
  318.       BeginProperty Font 
  319.          Name            =   "Verdana"
  320.          Size            =   9.75
  321.          Charset         =   0
  322.          Weight          =   700
  323.          Underline       =   0   'False
  324.          Italic          =   0   'False
  325.          Strikethrough   =   0   'False
  326.       EndProperty
  327.       Height          =   2655
  328.       Left            =   30
  329.       TabIndex        =   32
  330.       Top             =   1620
  331.       Width           =   7695
  332.       Begin VB.Label Label10 
  333.          BackColor       =   &H00FFFFFF&
  334.          Caption         =   "Landmark:"
  335.          BeginProperty Font 
  336.             Name            =   "Verdana"
  337.             Size            =   9.75
  338.             Charset         =   0
  339.             Weight          =   700
  340.             Underline       =   0   'False
  341.             Italic          =   0   'False
  342.             Strikethrough   =   0   'False
  343.          EndProperty
  344.          ForeColor       =   &H00404040&
  345.          Height          =   285
  346.          Left            =   150
  347.          TabIndex        =   51
  348.          Top             =   1980
  349.          Width           =   1185
  350.       End
  351.       Begin VB.Label lblcomp_landmark 
  352.          BackColor       =   &H00FFFFFF&
  353.          BeginProperty Font 
  354.             Name            =   "Verdana"
  355.             Size            =   8.25
  356.             Charset         =   0
  357.             Weight          =   400
  358.             Underline       =   0   'False
  359.             Italic          =   0   'False
  360.             Strikethrough   =   0   'False
  361.          EndProperty
  362.          ForeColor       =   &H00404040&
  363.          Height          =   405
  364.          Left            =   2100
  365.          TabIndex        =   50
  366.          Top             =   1980
  367.          Width           =   5205
  368.       End
  369.       Begin VB.Label lblemail 
  370.          BackColor       =   &H00FFFFFF&
  371.          Caption         =   "Email:"
  372.          BeginProperty Font 
  373.             Name            =   "Verdana"
  374.             Size            =   9.75
  375.             Charset         =   0
  376.             Weight          =   700
  377.             Underline       =   0   'False
  378.             Italic          =   0   'False
  379.             Strikethrough   =   0   'False
  380.          EndProperty
  381.          ForeColor       =   &H00404040&
  382.          Height          =   255
  383.          Left            =   4290
  384.          TabIndex        =   49
  385.          Top             =   1590
  386.          Width           =   675
  387.       End
  388.       Begin VB.Label lblcomp_custemail 
  389.          BackColor       =   &H00FFFFFF&
  390.          BeginProperty Font 
  391.             Name            =   "Verdana"
  392.             Size            =   8.25
  393.             Charset         =   0
  394.             Weight          =   400
  395.             Underline       =   0   'False
  396.             Italic          =   0   'False
  397.             Strikethrough   =   0   'False
  398.          EndProperty
  399.          ForeColor       =   &H00404040&
  400.          Height          =   255
  401.          Left            =   5340
  402.          TabIndex        =   48
  403.          Top             =   1590
  404.          Width           =   1965
  405.       End
  406.       Begin VB.Label lblcomp_fax 
  407.          BackColor       =   &H00FFFFFF&
  408.          BeginProperty Font 
  409.             Name            =   "Verdana"
  410.             Size            =   8.25
  411.             Charset         =   0
  412.             Weight          =   400
  413.             Underline       =   0   'False
  414.             Italic          =   0   'False
  415.             Strikethrough   =   0   'False
  416.          EndProperty
  417.          ForeColor       =   &H00404040&
  418.          Height          =   255
  419.          Left            =   5310
  420.          TabIndex        =   46
  421.          Top             =   1320
  422.          Width           =   1665
  423.       End
  424.       Begin VB.Label Label2 
  425.          BackColor       =   &H00FFFFFF&
  426.          Caption         =   "Fax:"
  427.          BeginProperty Font 
  428.             Name            =   "Verdana"
  429.             Size            =   9.75
  430.             Charset         =   0
  431.             Weight          =   700
  432.             Underline       =   0   'False
  433.             Italic          =   0   'False
  434.             Strikethrough   =   0   'False
  435.          EndProperty
  436.          ForeColor       =   &H00404040&
  437.          Height          =   255
  438.          Left            =   4290
  439.          TabIndex        =   45
  440.          Top             =   1320
  441.          Width           =   465
  442.       End
  443.       Begin VB.Label lblcomp_custph2 
  444.          BackColor       =   &H00FFFFFF&
  445.          BeginProperty Font 
  446.             Name            =   "Verdana"
  447.             Size            =   8.25
  448.             Charset         =   0
  449.             Weight          =   400
  450.             Underline       =   0   'False
  451.             Italic          =   0   'False
  452.             Strikethrough   =   0   'False
  453.          EndProperty
  454.          ForeColor       =   &H00404040&
  455.          Height          =   165
  456.          Left            =   5310
  457.          TabIndex        =   44
  458.          Top             =   1080
  459.          Width           =   1485
  460.       End
  461.       Begin VB.Label lblcomp_custpin 
  462.          BackColor       =   &H00FFFFFF&
  463.          BeginProperty Font 
  464.             Name            =   "Verdana"
  465.             Size            =   8.25
  466.             Charset         =   0
  467.             Weight          =   400
  468.             Underline       =   0   'False
  469.             Italic          =   0   'False
  470.             Strikethrough   =   0   'False
  471.          EndProperty
  472.          ForeColor       =   &H00404040&
  473.          Height          =   165
  474.          Left            =   2100
  475.          TabIndex        =   43
  476.          Top             =   1680
  477.          Width           =   1005
  478.       End
  479.       Begin VB.Label lblcomp_custstate 
  480.          BackColor       =   &H00FFFFFF&
  481.          BeginProperty Font 
  482.             Name            =   "Verdana"
  483.             Size            =   8.25
  484.             Charset         =   0
  485.             Weight          =   400
  486.             Underline       =   0   'False
  487.             Italic          =   0   'False
  488.             Strikethrough   =   0   'False
  489.          EndProperty
  490.          ForeColor       =   &H00404040&
  491.          Height          =   165
  492.          Left            =   2130
  493.          TabIndex        =   42
  494.          Top             =   1410
  495.          Width           =   2205
  496.       End
  497.       Begin VB.Label lblcomp_custcity 
  498.          BackColor       =   &H00FFFFFF&
  499.          BeginProperty Font 
  500.             Name            =   "Verdana"
  501.             Size            =   8.25
  502.             Charset         =   0
  503.             Weight          =   400
  504.             Underline       =   0   'False
  505.             Italic          =   0   'False
  506.             Strikethrough   =   0   'False
  507.          EndProperty
  508.          ForeColor       =   &H00404040&
  509.          Height          =   165
  510.          Left            =   2130
  511.          TabIndex        =   41
  512.          Top             =   1140
  513.          Width           =   2160
  514.       End
  515.       Begin VB.Label lblcomp_custadd 
  516.          BackColor       =   &H00FFFFFF&
  517.          BeginProperty Font 
  518.             Name            =   "Verdana"
  519.             Size            =   8.25
  520.             Charset         =   0
  521.             Weight          =   400
  522.             Underline       =   0   'False
  523.             Italic          =   0   'False
  524.             Strikethrough   =   0   'False
  525.          EndProperty
  526.          ForeColor       =   &H00404040&
  527.          Height          =   360
  528.          Left            =   2130
  529.          TabIndex        =   40
  530.          Top             =   660
  531.          Width           =   3780
  532.       End
  533.       Begin VB.Label lblcomp_custname 
  534.          BackColor       =   &H00FFFFFF&
  535.          BeginProperty Font 
  536.             Name            =   "Verdana"
  537.             Size            =   8.25
  538.             Charset         =   0
  539.             Weight          =   400
  540.             Underline       =   0   'False
  541.             Italic          =   0   'False
  542.             Strikethrough   =   0   'False
  543.          EndProperty
  544.          ForeColor       =   &H00404040&
  545.          Height          =   195
  546.          Left            =   2130
  547.          TabIndex        =   39
  548.          Top             =   330
  549.          Width           =   2970
  550.       End
  551.       Begin VB.Label Label3 
  552.          BackColor       =   &H00FFFFFF&
  553.          Caption         =   "Phone2:"
  554.          BeginProperty Font 
  555.             Name            =   "Verdana"
  556.             Size            =   9.75
  557.             Charset         =   0
  558.             Weight          =   700
  559.             Underline       =   0   'False
  560.             Italic          =   0   'False
  561.             Strikethrough   =   0   'False
  562.          EndProperty
  563.          ForeColor       =   &H00404040&
  564.          Height          =   255
  565.          Left            =   4290
  566.          TabIndex        =   38
  567.          Top             =   1080
  568.          Width           =   1095
  569.       End
  570.       Begin VB.Label Label4 
  571.          BackColor       =   &H00FFFFFF&
  572.          Caption         =   "Pincode:"
  573.          BeginProperty Font 
  574.             Name            =   "Verdana"
  575.             Size            =   9.75
  576.             Charset         =   0
  577.             Weight          =   700
  578.             Underline       =   0   'False
  579.             Italic          =   0   'False
  580.             Strikethrough   =   0   'False
  581.          EndProperty
  582.          ForeColor       =   &H00404040&
  583.          Height          =   285
  584.          Left            =   150
  585.          TabIndex        =   37
  586.          Top             =   1680
  587.          Width           =   915
  588.       End
  589.       Begin VB.Label Label5 
  590.          BackColor       =   &H00FFFFFF&
  591.          Caption         =   "State:"
  592.          BeginProperty Font 
  593.             Name            =   "Verdana"
  594.             Size            =   9.75
  595.             Charset         =   0
  596.             Weight          =   700
  597.             Underline       =   0   'False
  598.             Italic          =   0   'False
  599.             Strikethrough   =   0   'False
  600.          EndProperty
  601.          ForeColor       =   &H00404040&
  602.          Height          =   255
  603.          Left            =   150
  604.          TabIndex        =   36
  605.          Top             =   1410
  606.          Width           =   675
  607.       End
  608.       Begin VB.Label Label6 
  609.          BackColor       =   &H00FFFFFF&
  610.          Caption         =   "City:"
  611.          BeginProperty Font 
  612.             Name            =   "Verdana"
  613.             Size            =   9.75
  614.             Charset         =   0
  615.             Weight          =   700
  616.             Underline       =   0   'False
  617.             Italic          =   0   'False
  618.             Strikethrough   =   0   'False
  619.          EndProperty
  620.          ForeColor       =   &H00404040&
  621.          Height          =   255
  622.          Left            =   150
  623.          TabIndex        =   35
  624.          Top             =   1140
  625.          Width           =   555
  626.       End
  627.       Begin VB.Label Label7 
  628.          BackColor       =   &H00FFFFFF&
  629.          Caption         =   "Address:"
  630.          BeginProperty Font 
  631.             Name            =   "Verdana"
  632.             Size            =   9.75
  633.             Charset         =   0
  634.             Weight          =   700
  635.             Underline       =   0   'False
  636.             Italic          =   0   'False
  637.             Strikethrough   =   0   'False
  638.          EndProperty
  639.          ForeColor       =   &H00404040&
  640.          Height          =   255
  641.          Left            =   150
  642.          TabIndex        =   34
  643.          Top             =   660
  644.          Width           =   1035
  645.       End
  646.       Begin VB.Label Label9 
  647.          BackColor       =   &H00FFFFFF&
  648.          Caption         =   "Customer Name:"
  649.          DataSource      =   "comp_data"
  650.          BeginProperty Font 
  651.             Name            =   "Verdana"
  652.             Size            =   9.75
  653.             Charset         =   0
  654.             Weight          =   700
  655.             Underline       =   0   'False
  656.             Italic          =   0   'False
  657.             Strikethrough   =   0   'False
  658.          EndProperty
  659.          ForeColor       =   &H00404040&
  660.          Height          =   255
  661.          Left            =   120
  662.          TabIndex        =   33
  663.          Top             =   330
  664.          Width           =   2475
  665.       End
  666.    End
  667.    Begin VB.TextBox comp_no 
  668.       Appearance      =   0  'Flat
  669.       BackColor       =   &H00FFFFFF&
  670.       BeginProperty Font 
  671.          Name            =   "Verdana"
  672.          Size            =   8.25
  673.          Charset         =   0
  674.          Weight          =   400
  675.          Underline       =   0   'False
  676.          Italic          =   0   'False
  677.          Strikethrough   =   0   'False
  678.       EndProperty
  679.       ForeColor       =   &H00FF0000&
  680.       Height          =   285
  681.       Left            =   2880
  682.       MaxLength       =   7
  683.       TabIndex        =   5
  684.       Top             =   6060
  685.       Width           =   1005
  686.    End
  687.    Begin VB.Frame Frame1 
  688.       BackColor       =   &H00FFFFFF&
  689.       BeginProperty Font 
  690.          Name            =   "Verdana"
  691.          Size            =   9
  692.          Charset         =   0
  693.          Weight          =   700
  694.          Underline       =   0   'False
  695.          Italic          =   0   'False
  696.          Strikethrough   =   0   'False
  697.       EndProperty
  698.       Height          =   765
  699.       Left            =   0
  700.       TabIndex        =   30
  701.       Top             =   780
  702.       Width           =   4515
  703.       Begin VB.ComboBox comp_custph1 
  704.          Appearance      =   0  'Flat
  705.          BackColor       =   &H00FFFFFF&
  706.          BeginProperty Font 
  707.             Name            =   "Verdana"
  708.             Size            =   8.25
  709.             Charset         =   0
  710.             Weight          =   400
  711.             Underline       =   0   'False
  712.             Italic          =   0   'False
  713.             Strikethrough   =   0   'False
  714.          EndProperty
  715.          ForeColor       =   &H00FF0000&
  716.          Height          =   315
  717.          Left            =   2460
  718.          TabIndex        =   0
  719.          Top             =   270
  720.          Width           =   1785
  721.       End
  722.       Begin VB.Label Label1 
  723.          BackColor       =   &H00FFFFFF&
  724.          Caption         =   "Customer Phone No:"
  725.          BeginProperty Font 
  726.             Name            =   "Verdana"
  727.             Size            =   9.75
  728.             Charset         =   0
  729.             Weight          =   700
  730.             Underline       =   0   'False
  731.             Italic          =   0   'False
  732.             Strikethrough   =   0   'False
  733.          EndProperty
  734.          Height          =   285
  735.          Left            =   120
  736.          TabIndex        =   31
  737.          Top             =   270
  738.          Width           =   2325
  739.       End
  740.    End
  741.    Begin VB.Frame file_frame 
  742.       BackColor       =   &H00E0E0E0&
  743.       Height          =   840
  744.       Left            =   0
  745.       TabIndex        =   29
  746.       Top             =   -60
  747.       Width           =   4275
  748.       Begin VB.CommandButton comp_delete 
  749.          Caption         =   "&Delete"
  750.          BeginProperty Font 
  751.             Name            =   "Verdana"
  752.             Size            =   8.25
  753.             Charset         =   0
  754.             Weight          =   400
  755.             Underline       =   0   'False
  756.             Italic          =   0   'False
  757.             Strikethrough   =   0   'False
  758.          EndProperty
  759.          Height          =   645
  760.          Left            =   855
  761.          Picture         =   "complaints.frx":0018
  762.          Style           =   1  'Graphical
  763.          TabIndex        =   12
  764.          ToolTipText     =   "DELETE"
  765.          Top             =   120
  766.          Width           =   820
  767.       End
  768.       Begin VB.CommandButton comp_undo 
  769.          Caption         =   "&Undo"
  770.          BeginProperty Font 
  771.             Name            =   "Verdana"
  772.             Size            =   8.25
  773.             Charset         =   0
  774.             Weight          =   400
  775.             Underline       =   0   'False
  776.             Italic          =   0   'False
  777.             Strikethrough   =   0   'False
  778.          EndProperty
  779.          Height          =   645
  780.          Left            =   2535
  781.          Picture         =   "complaints.frx":01A2
  782.          Style           =   1  'Graphical
  783.          TabIndex        =   14
  784.          ToolTipText     =   "UNDO"
  785.          Top             =   120
  786.          Width           =   820
  787.       End
  788.       Begin VB.CommandButton comp_query 
  789.          Caption         =   "&Query"
  790.          BeginProperty Font 
  791.             Name            =   "Verdana"
  792.             Size            =   8.25
  793.             Charset         =   0
  794.             Weight          =   400
  795.             Underline       =   0   'False
  796.             Italic          =   0   'False
  797.             Strikethrough   =   0   'False
  798.          EndProperty
  799.          Height          =   645
  800.          Left            =   1695
  801.          Picture         =   "complaints.frx":080C
  802.          Style           =   1  'Graphical
  803.          TabIndex        =   13
  804.          ToolTipText     =   "QUERY"
  805.          Top             =   120
  806.          Width           =   820
  807.       End
  808.       Begin VB.CommandButton comp_help 
  809.          Caption         =   "&Help"
  810.          BeginProperty Font 
  811.             Name            =   "Verdana"
  812.             Size            =   8.25
  813.             Charset         =   0
  814.             Weight          =   400
  815.             Underline       =   0   'False
  816.             Italic          =   0   'False
  817.             Strikethrough   =   0   'False
  818.          EndProperty
  819.          Height          =   645
  820.          Index           =   0
  821.          Left            =   3375
  822.          Picture         =   "complaints.frx":090E
  823.          Style           =   1  'Graphical
  824.          TabIndex        =   15
  825.          ToolTipText     =   "HELP"
  826.          Top             =   120
  827.          Width           =   820
  828.       End
  829.       Begin VB.CommandButton comp_save 
  830.          Caption         =   "&Save"
  831.          BeginProperty Font 
  832.             Name            =   "Verdana"
  833.             Size            =   8.25
  834.             Charset         =   0
  835.             Weight          =   400
  836.             Underline       =   0   'False
  837.             Italic          =   0   'False
  838.             Strikethrough   =   0   'False
  839.          EndProperty
  840.          Height          =   645
  841.          Left            =   40
  842.          Picture         =   "complaints.frx":0A10
  843.          Style           =   1  'Graphical
  844.          TabIndex        =   11
  845.          ToolTipText     =   "SAVE"
  846.          Top             =   120
  847.          UseMaskColor    =   -1  'True
  848.          Width           =   820
  849.       End
  850.    End
  851.    Begin VB.Frame navigation_frame 
  852.       Appearance      =   0  'Flat
  853.       BackColor       =   &H00E0E0E0&
  854.       ForeColor       =   &H80000008&
  855.       Height          =   810
  856.       Left            =   4320
  857.       TabIndex        =   28
  858.       Top             =   -60
  859.       Width           =   3030
  860.       Begin VB.CommandButton comp_bottom 
  861.          Caption         =   "&Bottom"
  862.          BeginProperty Font 
  863.             Name            =   "Verdana"
  864.             Size            =   8.25
  865.             Charset         =   0
  866.             Weight          =   400
  867.             Underline       =   0   'False
  868.             Italic          =   0   'False
  869.             Strikethrough   =   0   'False
  870.          EndProperty
  871.          Height          =   645
  872.          Index           =   0
  873.          Left            =   2280
  874.          Picture         =   "complaints.frx":107A
  875.          Style           =   1  'Graphical
  876.          TabIndex        =   19
  877.          ToolTipText     =   "BOTTOM"
  878.          Top             =   120
  879.          Width           =   700
  880.       End
  881.       Begin VB.CommandButton comp_next 
  882.          Caption         =   "&Next"
  883.          BeginProperty Font 
  884.             Name            =   "Verdana"
  885.             Size            =   8.25
  886.             Charset         =   0
  887.             Weight          =   400
  888.             Underline       =   0   'False
  889.             Italic          =   0   'False
  890.             Strikethrough   =   0   'False
  891.          EndProperty
  892.          Height          =   645
  893.          Left            =   1560
  894.          Picture         =   "complaints.frx":14BC
  895.          Style           =   1  'Graphical
  896.          TabIndex        =   18
  897.          Top             =   120
  898.          Width           =   700
  899.       End
  900.       Begin VB.CommandButton comp_top 
  901.          Caption         =   "&Top"
  902.          BeginProperty Font 
  903.             Name            =   "Verdana"
  904.             Size            =   8.25
  905.             Charset         =   0
  906.             Weight          =   400
  907.             Underline       =   0   'False
  908.             Italic          =   0   'False
  909.             Strikethrough   =   0   'False
  910.          EndProperty
  911.          Height          =   645
  912.          Left            =   45
  913.          Picture         =   "complaints.frx":18FE
  914.          Style           =   1  'Graphical
  915.          TabIndex        =   16
  916.          ToolTipText     =   "TOP"
  917.          Top             =   120
  918.          Width           =   675
  919.       End
  920.       Begin VB.CommandButton comp_previous 
  921.          Caption         =   "&Previous"
  922.          BeginProperty Font 
  923.             Name            =   "Verdana"
  924.             Size            =   8.25
  925.             Charset         =   0
  926.             Weight          =   400
  927.             Underline       =   0   'False
  928.             Italic          =   0   'False
  929.             Strikethrough   =   0   'False
  930.          EndProperty
  931.          Height          =   645
  932.          Left            =   735
  933.          Picture         =   "complaints.frx":1D40
  934.          Style           =   1  'Graphical
  935.          TabIndex        =   17
  936.          ToolTipText     =   "PREVIOUS"
  937.          Top             =   120
  938.          Width           =   820
  939.       End
  940.    End
  941.    Begin VB.Frame complaint_frame 
  942.       BackColor       =   &H00FFFFFF&
  943.       Caption         =   "Complaint Details:"
  944.       BeginProperty Font 
  945.          Name            =   "Verdana"
  946.          Size            =   9.75
  947.          Charset         =   0
  948.          Weight          =   700
  949.          Underline       =   0   'False
  950.          Italic          =   0   'False
  951.          Strikethrough   =   0   'False
  952.       EndProperty
  953.       Height          =   3825
  954.       Left            =   0
  955.       TabIndex        =   20
  956.       Top             =   4380
  957.       Width           =   9435
  958.       Begin VB.ComboBox comp_prdicno1 
  959.          Appearance      =   0  'Flat
  960.          BackColor       =   &H00FFFFFF&
  961.          ForeColor       =   &H00FF0000&
  962.          Height          =   315
  963.          Left            =   2880
  964.          TabIndex        =   3
  965.          Top             =   990
  966.          Width           =   2520
  967.       End
  968.       Begin VB.TextBox comp_attdate 
  969.          Appearance      =   0  'Flat
  970.          BackColor       =   &H00FFFFFF&
  971.          ForeColor       =   &H00FF0000&
  972.          Height          =   285
  973.          Left            =   2880
  974.          TabIndex        =   7
  975.          Top             =   2400
  976.          Width           =   1455
  977.       End
  978.       Begin VB.TextBox comp_madeby 
  979.          Appearance      =   0  'Flat
  980.          BackColor       =   &H00FFFFFF&
  981.          BeginProperty DataFormat 
  982.             Type            =   1
  983.             Format          =   "dd/MM/yyyy"
  984.             HaveTrueFalseNull=   0
  985.             FirstDayOfWeek  =   0
  986.             FirstWeekOfYear =   0
  987.             LCID            =   1039
  988.             SubFormatType   =   3
  989.          EndProperty
  990.          ForeColor       =   &H00FF0000&
  991.          Height          =   285
  992.          Left            =   2880
  993.          MaxLength       =   25
  994.          TabIndex        =   2
  995.          Top             =   660
  996.          Width           =   2500
  997.       End
  998.       Begin VB.ComboBox comp_status 
  999.          Appearance      =   0  'Flat
  1000.          BackColor       =   &H00FFFFFF&
  1001.          BeginProperty Font 
  1002.             Name            =   "Verdana"
  1003.             Size            =   8.25
  1004.             Charset         =   0
  1005.             Weight          =   400
  1006.             Underline       =   0   'False
  1007.             Italic          =   0   'False
  1008.             Strikethrough   =   0   'False
  1009.          EndProperty
  1010.          ForeColor       =   &H00FF0000&
  1011.          Height          =   315
  1012.          ItemData        =   "complaints.frx":2182
  1013.          Left            =   2880
  1014.          List            =   "complaints.frx":218C
  1015.          TabIndex        =   6
  1016.          Top             =   2040
  1017.          Width           =   1470
  1018.       End
  1019.       Begin VB.TextBox comp_cause 
  1020.          Appearance      =   0  'Flat
  1021.          BackColor       =   &H00FFFFFF&
  1022.          ForeColor       =   &H00FF0000&
  1023.          Height          =   285
  1024.          Left            =   2880
  1025.          MaxLength       =   50
  1026.          TabIndex        =   9
  1027.          Top             =   3060
  1028.          Width           =   6255
  1029.       End
  1030.       Begin VB.TextBox comp_date 
  1031.          Appearance      =   0  'Flat
  1032.          BackColor       =   &H00FFFFFF&
  1033.          BeginProperty DataFormat 
  1034.             Type            =   1
  1035.             Format          =   "dd/MM/yyyy"
  1036.             HaveTrueFalseNull=   0
  1037.             FirstDayOfWeek  =   0
  1038.             FirstWeekOfYear =   0
  1039.             LCID            =   1039
  1040.             SubFormatType   =   3
  1041.          EndProperty
  1042.          ForeColor       =   &H00FF0000&
  1043.          Height          =   285
  1044.          Left            =   2880
  1045.          MaxLength       =   10
  1046.          TabIndex        =   1
  1047.          Top             =   330
  1048.          Width           =   1125
  1049.       End
  1050.       Begin VB.TextBox comp_desc 
  1051.          Appearance      =   0  'Flat
  1052.          BackColor       =   &H00FFFFFF&
  1053.          BeginProperty Font 
  1054.             Name            =   "Verdana"
  1055.             Size            =   8.25
  1056.             Charset         =   0
  1057.             Weight          =   400
  1058.             Underline       =   0   'False
  1059.             Italic          =   0   'False
  1060.             Strikethrough   =   0   'False
  1061.          EndProperty
  1062.          ForeColor       =   &H00FF0000&
  1063.          Height          =   285
  1064.          Left            =   2865
  1065.          MaxLength       =   50
  1066.          TabIndex        =   4
  1067.          Top             =   1350
  1068.          Width           =   4245
  1069.       End
  1070.       Begin VB.TextBox comp_attby 
  1071.          Appearance      =   0  'Flat
  1072.          BackColor       =   &H00FFFFFF&
  1073.          ForeColor       =   &H00FF0000&
  1074.          Height          =   285
  1075.          Left            =   2880
  1076.          MaxLength       =   30
  1077.          TabIndex        =   8
  1078.          Top             =   2730
  1079.          Width           =   1725
  1080.       End
  1081.       Begin VB.TextBox comp_action 
  1082.          Appearance      =   0  'Flat
  1083.          BackColor       =   &H00FFFFFF&
  1084.          ForeColor       =   &H00FF0000&
  1085.          Height          =   285
  1086.          Left            =   2880
  1087.          MaxLength       =   100
  1088.          TabIndex        =   10
  1089.          Top             =   3390
  1090.          Width           =   4245
  1091.       End
  1092.       Begin VB.Label Label11 
  1093.          BackColor       =   &H00FFFFFF&
  1094.          Caption         =   "Installation Card No:"
  1095.          BeginProperty Font 
  1096.             Name            =   "Verdana"
  1097.             Size            =   9.75
  1098.             Charset         =   0
  1099.             Weight          =   700
  1100.             Underline       =   0   'False
  1101.             Italic          =   0   'False
  1102.             Strikethrough   =   0   'False
  1103.          EndProperty
  1104.          Height          =   195
  1105.          Left            =   150
  1106.          TabIndex        =   54
  1107.          Top             =   990
  1108.          Width           =   2265
  1109.       End
  1110.       Begin VB.Label Label8 
  1111.          BackColor       =   &H00FFFFFF&
  1112.          Caption         =   "Complaint Made By:"
  1113.          BeginProperty Font 
  1114.             Name            =   "Verdana"
  1115.             Size            =   9.75
  1116.             Charset         =   0
  1117.             Weight          =   700
  1118.             Underline       =   0   'False
  1119.             Italic          =   0   'False
  1120.             Strikethrough   =   0   'False
  1121.          EndProperty
  1122.          Height          =   195
  1123.          Left            =   150
  1124.          TabIndex        =   53
  1125.          Top             =   660
  1126.          Width           =   1755
  1127.       End
  1128.       Begin VB.Label lblcomp_no 
  1129.          BackColor       =   &H00FFFFFF&
  1130.          Caption         =   "Complaint No:"
  1131.          BeginProperty Font 
  1132.             Name            =   "Verdana"
  1133.             Size            =   9.75
  1134.             Charset         =   0
  1135.             Weight          =   700
  1136.             Underline       =   0   'False
  1137.             Italic          =   0   'False
  1138.             Strikethrough   =   0   'False
  1139.          EndProperty
  1140.          Height          =   225
  1141.          Left            =   150
  1142.          TabIndex        =   52
  1143.          Top             =   1650
  1144.          Width           =   1530
  1145.       End
  1146.       Begin VB.Label lblcomp_action 
  1147.          BackColor       =   &H00FFFFFF&
  1148.          Caption         =   "Action Taken:"
  1149.          BeginProperty Font 
  1150.             Name            =   "Verdana"
  1151.             Size            =   9.75
  1152.             Charset         =   0
  1153.             Weight          =   700
  1154.             Underline       =   0   'False
  1155.             Italic          =   0   'False
  1156.             Strikethrough   =   0   'False
  1157.          EndProperty
  1158.          ForeColor       =   &H00000000&
  1159.          Height          =   255
  1160.          Left            =   150
  1161.          TabIndex        =   27
  1162.          Top             =   3390
  1163.          Width           =   1575
  1164.       End
  1165.       Begin VB.Label lbldate 
  1166.          BackColor       =   &H00FFFFFF&
  1167.          Caption         =   "Complaint Date:"
  1168.          BeginProperty Font 
  1169.             Name            =   "Verdana"
  1170.             Size            =   9.75
  1171.             Charset         =   0
  1172.             Weight          =   700
  1173.             Underline       =   0   'False
  1174.             Italic          =   0   'False
  1175.             Strikethrough   =   0   'False
  1176.          EndProperty
  1177.          Height          =   195
  1178.          Left            =   150
  1179.          TabIndex        =   26
  1180.          Top             =   330
  1181.          Width           =   1515
  1182.       End
  1183.       Begin VB.Label lbldesc 
  1184.          BackColor       =   &H00FFFFFF&
  1185.          Caption         =   "Complaint Description:"
  1186.          BeginProperty Font 
  1187.             Name            =   "Verdana"
  1188.             Size            =   9.75
  1189.             Charset         =   0
  1190.             Weight          =   700
  1191.             Underline       =   0   'False
  1192.             Italic          =   0   'False
  1193.             Strikethrough   =   0   'False
  1194.          EndProperty
  1195.          Height          =   195
  1196.          Left            =   120
  1197.          TabIndex        =   25
  1198.          Top             =   1320
  1199.          Width           =   2475
  1200.       End
  1201.       Begin VB.Label lblattdate 
  1202.          BackColor       =   &H00FFFFFF&
  1203.          Caption         =   "Complaint Cause:"
  1204.          BeginProperty Font 
  1205.             Name            =   "Verdana"
  1206.             Size            =   9.75
  1207.             Charset         =   0
  1208.             Weight          =   700
  1209.             Underline       =   0   'False
  1210.             Italic          =   0   'False
  1211.             Strikethrough   =   0   'False
  1212.          EndProperty
  1213.          Height          =   315
  1214.          Left            =   120
  1215.          TabIndex        =   24
  1216.          Top             =   3060
  1217.          Width           =   2025
  1218.       End
  1219.       Begin VB.Label lblcomp_attby 
  1220.          BackColor       =   &H00FFFFFF&
  1221.          Caption         =   "Complaint Attended. by:"
  1222.          BeginProperty Font 
  1223.             Name            =   "Verdana"
  1224.             Size            =   9.75
  1225.             Charset         =   0
  1226.             Weight          =   700
  1227.             Underline       =   0   'False
  1228.             Italic          =   0   'False
  1229.             Strikethrough   =   0   'False
  1230.          EndProperty
  1231.          Height          =   315
  1232.          Left            =   120
  1233.          TabIndex        =   23
  1234.          Top             =   2730
  1235.          Width           =   2715
  1236.       End
  1237.       Begin VB.Label lblcomments 
  1238.          BackColor       =   &H00FFFFFF&
  1239.          Caption         =   "Attended On:"
  1240.          BeginProperty Font 
  1241.             Name            =   "Verdana"
  1242.             Size            =   9.75
  1243.             Charset         =   0
  1244.             Weight          =   700
  1245.             Underline       =   0   'False
  1246.             Italic          =   0   'False
  1247.             Strikethrough   =   0   'False
  1248.          EndProperty
  1249.          ForeColor       =   &H00000000&
  1250.          Height          =   285
  1251.          Left            =   120
  1252.          TabIndex        =   22
  1253.          Top             =   2400
  1254.          Width           =   1545
  1255.       End
  1256.       Begin VB.Label lblcomp_status 
  1257.          BackColor       =   &H00FFFFFF&
  1258.          Caption         =   "Status:"
  1259.          BeginProperty Font 
  1260.             Name            =   "Verdana"
  1261.             Size            =   9.75
  1262.             Charset         =   0
  1263.             Weight          =   700
  1264.             Underline       =   0   'False
  1265.             Italic          =   0   'False
  1266.             Strikethrough   =   0   'False
  1267.          EndProperty
  1268.          ForeColor       =   &H00000000&
  1269.          Height          =   255
  1270.          Left            =   120
  1271.          TabIndex        =   21
  1272.          Top             =   2040
  1273.          Width           =   855
  1274.       End
  1275.    End
  1276. End
  1277. Attribute VB_Name = "complaintsfrm"
  1278. Attribute VB_GlobalNameSpace = False
  1279. Attribute VB_Creatable = False
  1280. Attribute VB_PredeclaredId = True
  1281. Attribute VB_Exposed = False
  1282. Dim compinsert, undoclick, ctr, recvalidated As Integer
  1283. Dim confirmadd, presentcontrol, curcomp_no, confirmdelete As String
  1284. Private Sub comp_action_KeyPress(KeyAscii As Integer)
  1285. If KeyAscii = 13 Then
  1286.   SendKeys "{TAB}", True
  1287. End If
  1288. End Sub
  1289. Private Sub comp_action_KeyUp(KeyCode As Integer, Shift As Integer)
  1290. If complaintsfrm.ActiveControl = comp_action Then
  1291.     complaints_wchange
  1292. End If
  1293. End Sub
  1294. Private Sub comp_attby_KeyPress(KeyAscii As Integer)
  1295. If KeyAscii = 13 Then
  1296.   SendKeys "{TAB}", True
  1297. End If
  1298. End Sub
  1299. Private Sub comp_attby_KeyUp(KeyCode As Integer, Shift As Integer)
  1300. If complaintsfrm.ActiveControl = comp_attby Then
  1301.     complaints_wchange
  1302. End If
  1303. End Sub
  1304. Private Sub comp_attdate_KeyPress(KeyAscii As Integer)
  1305. If KeyAscii = 13 Then
  1306.   SendKeys "{TAB}", True
  1307. End If
  1308. If KeyAscii = 8 Or KeyAscii = 32 Or KeyAscii = 47 Then
  1309.   Exit Sub
  1310. End If
  1311. If KeyAscii < 48 Or KeyAscii > 57 Then
  1312.   KeyAscii = 0
  1313. End If
  1314. End Sub
  1315. Private Sub comp_attdate_KeyUp(KeyCode As Integer, Shift As Integer)
  1316. If complaintsfrm.ActiveControl = comp_attdate Then
  1317.     complaints_wchange
  1318. End If
  1319. End Sub
  1320. Private Sub comp_attdate_LostFocus()
  1321. If comp_attdate = "" Then
  1322.     Exit Sub
  1323. End If
  1324. If IsDate(comp_attdate) Then
  1325.     comp_attdate.Text = CDate(comp_attdate)
  1326. Else
  1327.     MsgBox ("Please Enter A Valid Attendence Date")
  1328.     comp_attdate.SetFocus
  1329. End If
  1330. End Sub
  1331. Private Sub comp_cause_KeyPress(KeyAscii As Integer)
  1332. If KeyAscii = 13 Then
  1333.   SendKeys "{TAB}", True
  1334. End If
  1335. End Sub
  1336. Private Sub comp_cause_KeyUp(KeyCode As Integer, Shift As Integer)
  1337. If complaintsfrm.ActiveControl = comp_action Then
  1338.     complaints_wchange
  1339. End If
  1340. End Sub
  1341. Private Sub comp_custph1_Click()
  1342. mastershow
  1343. End Sub
  1344. Private Sub comp_custph1_KeyPress(KeyAscii As Integer)
  1345. If KeyAscii = 13 Then
  1346.   SendKeys "{TAB}", True
  1347. End If
  1348. If KeyAscii = 8 Or KeyAscii = 32 Then
  1349.   Exit Sub
  1350. End If
  1351. If KeyAscii < 48 Or KeyAscii > 57 Then
  1352.   KeyAscii = 0
  1353. End If
  1354. End Sub
  1355. Private Sub comp_custph1_LostFocus()
  1356. prodinstfrm.setcustcom
  1357. prodinstfrm.custrs.Filter = "cust_ph1='" & comp_custph1 & "'"
  1358. If prodinstfrm.custrs.EOF = True Or prodinstfrm.custrs.BOF = True Then
  1359.     compconfirmcustph1add
  1360. End If
  1361. End Sub
  1362.  
  1363. Private Sub comp_date_KeyPress(KeyAscii As Integer)
  1364. If KeyAscii = 13 Then
  1365.   SendKeys "{TAB}", True
  1366. End If
  1367. If KeyAscii = 8 Or KeyAscii = 32 Or KeyAscii = 47 Then
  1368.   Exit Sub
  1369. End If
  1370. If KeyAscii < 48 Or KeyAscii > 57 Then
  1371.   KeyAscii = 0
  1372. End If
  1373. End Sub
  1374. Private Sub comp_date_KeyUp(KeyCode As Integer, Shift As Integer)
  1375. detailshow
  1376. End Sub
  1377. Private Sub comp_date_LostFocus()
  1378. If IsDate(comp_date) Then
  1379.     comp_date.Text = CDate(comp_date)
  1380. Else
  1381.     MsgBox ("Please Enter A Valid Complaint Date")
  1382.     comp_date.SetFocus
  1383. End If
  1384. End Sub
  1385. Private Sub comp_desc_KeyPress(KeyAscii As Integer)
  1386. If KeyAscii = 13 Then
  1387.   SendKeys "{TAB}", True
  1388. End If
  1389. End Sub
  1390. Private Sub comp_desc_KeyUp(KeyCode As Integer, Shift As Integer)
  1391. If complaintsfrm.ActiveControl = comp_desc Then
  1392.     complaints_wchange
  1393. End If
  1394. End Sub
  1395. Private Sub comp_grid_AfterDelete()
  1396. prodinstfrm.setcomptempcom
  1397. If prodinstfrm.comptemprs.RecordCount > 0 Then
  1398.     prodinstfrm.comptemprs.MoveNext
  1399.     If prodinstfrm.comptemprs.EOF = True Then
  1400.         prodinstfrm.comptemprs.MovePrevious
  1401.     End If
  1402.     comp_date.Text = prodinstfrm.comptemprs.Fields(1)
  1403.     showrecords1
  1404.     Else
  1405.     blankrecords
  1406. End If
  1407. End Sub
  1408. Private Sub comp_grid_BeforeDelete(Cancel As Integer)
  1409. prodinstfrm.custcaredb.Execute ("delete * from complaints where comp_custph1='" & comp_custph1 & "' and cstr(comp_date)='" & CStr(comp_date) & "'")
  1410. End Sub
  1411. Private Sub comp_grid_Click()
  1412. gridchange
  1413. End Sub
  1414. Private Sub comp_grid_KeyUp(KeyCode As Integer, Shift As Integer)
  1415. gridchange
  1416. End Sub
  1417. Private Sub comp_madeby_KeyPress(KeyAscii As Integer)
  1418. If KeyAscii = 13 Then
  1419.   SendKeys "{TAB}", True
  1420. End If
  1421. End Sub
  1422. Private Sub comp_madeby_KeyUp(KeyCode As Integer, Shift As Integer)
  1423. If complaintsfrm.ActiveControl = comp_madeby Then
  1424.     complaints_wchange
  1425. End If
  1426. End Sub
  1427. Private Sub comp_no_GotFocus()
  1428. If comp_no.Text = "" Then
  1429.     comp_no = "0" + CStr(Month(Date))
  1430. End If
  1431. End Sub
  1432. Private Sub comp_no_KeyPress(KeyAscii As Integer)
  1433. If KeyAscii = 13 Then
  1434.   SendKeys "{TAB}", True
  1435. End If
  1436. If KeyAscii = 8 Or KeyAscii = 32 Then
  1437.   Exit Sub
  1438. End If
  1439. If KeyAscii < 48 Or KeyAscii > 57 Then
  1440.   KeyAscii = 0
  1441. End If
  1442. End Sub
  1443. Private Sub comp_no_KeyUp(KeyCode As Integer, Shift As Integer)
  1444. If complaintsfrm.ActiveControl = comp_no Then
  1445.     complaints_wchange
  1446. End If
  1447. End Sub
  1448. Private Sub comp_no_LostFocus()
  1449. If comp_no.Text = "" Then
  1450.     comp_no = "0" + CStr(Month(Date))
  1451. End If
  1452. End Sub
  1453. Private Sub comp_prdicno1_Click()
  1454. showprodinfo
  1455. End Sub
  1456. Private Sub comp_prdicno1_GotFocus()
  1457. showprodinfo
  1458. End Sub
  1459. Private Sub comp_prdicno1_KeyPress(KeyAscii As Integer)
  1460. If KeyAscii = 13 Then
  1461.   SendKeys "{TAB}", True
  1462. End If
  1463. KeyAscii = 0
  1464. End Sub
  1465. Private Sub comp_prdicno1_KeyUp(KeyCode As Integer, Shift As Integer)
  1466. If complaintsfrm.ActiveControl = comp_prdicno1 Then
  1467.     complaints_wchange
  1468. End If
  1469. showprodinfo
  1470. End Sub
  1471. Private Sub comp_prdicno1_LostFocus()
  1472. comp_prodinfo.Visible = False
  1473. End Sub
  1474. Private Sub comp_prdicno11_GotFocus()
  1475. showprodinfo
  1476. End Sub
  1477.  
  1478. Private Sub comp_status_Click()
  1479. complaints_wchange
  1480. If comp_status = "Pending" Then
  1481.     comp_attdate.Enabled = False
  1482.     comp_attdate.BackColor = &H80000012
  1483.     comp_attby.Enabled = False
  1484.     comp_attby.BackColor = &H80000012
  1485.     comp_cause.Enabled = False
  1486.     comp_cause.BackColor = &H80000012
  1487.     comp_action.Enabled = False
  1488.     comp_action.BackColor = &H80000012
  1489.     Else
  1490.     comp_attdate.Enabled = True
  1491.     comp_attdate.BackColor = &HFFFFFF
  1492.     comp_attby.Enabled = True
  1493.     comp_attby.BackColor = &HFFFFFF
  1494.     comp_cause.Enabled = True
  1495.     comp_cause.BackColor = &HFFFFFF
  1496.     comp_action.Enabled = True
  1497.     comp_action.BackColor = &HFFFFFF
  1498. End If
  1499. End Sub
  1500. Private Sub Comp_status_KeyPress(KeyAscii As Integer)
  1501. If KeyAscii = 13 Then
  1502.     SendKeys "{TAB}", True
  1503. End If
  1504. KeyAscii = 0
  1505. End Sub
  1506. Private Sub comp_next_Click()
  1507. ctr = 1
  1508. If prodinstfrm.comprs.RecordCount > 0 Then
  1509.     comp_save = True
  1510.     If recvalidated = 0 Then
  1511.         Exit Sub
  1512.         Else
  1513.         recvalidated = 0
  1514.     End If
  1515.     prodinstfrm.setcomptempcom
  1516.     prodinstfrm.comptemprs.Filter = "comp_custph1='" & comp_custph1 & "' and comp_date='" & CDate(comp_date) & "'"
  1517.     prodinstfrm.setcomptempcom
  1518.     prodinstfrm.comptemprs.MovePrevious
  1519.     If prodinstfrm.comptemprs.BOF Then
  1520.         prodinstfrm.comptemprs.MoveNext
  1521.     End If
  1522.     comp_date.Text = prodinstfrm.comptemprs.Fields(1)
  1523.     showrecords1
  1524. End If
  1525. End Sub
  1526. Private Sub comp_custph1_KeyUp(KeyCode As Integer, Shift As Integer)
  1527. If KeyCode = 18 Or KeyCode = 80 Or KeyCode = 84 Or KeyCode = 66 Or KeyCode = 78 Or KeyCode = 13 Or KeyCode = 83 Then
  1528.     Exit Sub
  1529. End If
  1530. mastershow
  1531. End Sub
  1532. Private Sub comp_status_KeyUp(KeyCode As Integer, Shift As Integer)
  1533. If complaintsfrm.ActiveControl = comp_status Then
  1534.     complaints_wchange
  1535. End If
  1536. End Sub
  1537. Private Sub Form_Activate()
  1538. If newcomplaint = 1 Then
  1539.     comp_custph1.Text = curcustph1
  1540.     newcomplaint = 0
  1541.     comp_custph1.SetFocus
  1542.     mastershow
  1543.     Exit Sub
  1544. End If
  1545.  
  1546. If newcomplaint = 2 Then
  1547.     comp_custph1.Text = curcustph1
  1548.     comp_date.Text = curcustdate
  1549.     comp_custph1.SetFocus
  1550.     mastershow
  1551.     newcomplaint = 0
  1552.     Exit Sub
  1553. End If
  1554.  
  1555. ctr = 0
  1556. recvalidated = 0
  1557. compinsert = 0
  1558. comp_custph1.SetFocus
  1559. comp_undo.Enabled = False
  1560.  
  1561. 'setting database connection
  1562. prodinstfrm.setcustcom
  1563. prodinstfrm.setprodtemp
  1564. prodinstfrm.setprodcom
  1565. prodinstfrm.setcomptempcom
  1566. prodinstfrm.setcompcom
  1567.  
  1568. 'filling phone1 combo box
  1569. prodinstfrm.setcustcom
  1570. If prodinstfrm.custrs.RecordCount > 0 Then
  1571.     prodinstfrm.custrs.MoveFirst
  1572.     Do While Not prodinstfrm.custrs.EOF
  1573.         comp_custph1.AddItem (prodinstfrm.custrs.Fields(5))
  1574.         prodinstfrm.custrs.MoveNext
  1575.     Loop
  1576.     comp_custph1.Text = comp_custph1.List(0)
  1577.     prodinstfrm.custrs.Filter = "cust_ph1='" & comp_custph1 & "'"
  1578.     If prodinstfrm.custrs.BOF = False And prodinstfrm.custrs.EOF = False Then
  1579.         showrecords
  1580.     End If
  1581. End If
  1582.  
  1583. 'filling product no combo box
  1584. fillprodicno
  1585.  
  1586. 'if recordcount=0 then blank
  1587. prodinstfrm.setcompcom
  1588. If prodinstfrm.comprs.RecordCount = 0 Then
  1589.   compinsert = 1
  1590.   comp_date = Date
  1591.   comp_no = "1"
  1592.   blankrecords
  1593.   comp_delete.Enabled = False
  1594.   comp_query.Enabled = False
  1595.   comp_top.Enabled = False
  1596.   comp_bottom(0).Enabled = False
  1597.   comp_previous.Enabled = False
  1598.   comp_next.Enabled = False
  1599.   Else: mastershow
  1600. End If
  1601. End Sub
  1602. Public Sub blankrecords()
  1603. comp_madeby = ""
  1604. If comp_prdicno1.ListCount = 0 Then
  1605.     comp_prdicno1 = "0"
  1606. Else
  1607.     comp_prdicno1.Text = comp_prdicno1.List(0)
  1608. End If
  1609. If Month(Date) < 10 Then
  1610.     comp_no.Text = "0" + CStr(Month(Date))
  1611.     Else
  1612.     comp_no.Text = CStr(Month(Date))
  1613. End If
  1614. comp_desc = ""
  1615. comp_status.Text = comp_status.List(0)
  1616. comp_attdate.Text = ""
  1617. comp_attby.Text = ""
  1618. comp_cause.Text = ""
  1619. comp_action.Text = ""
  1620. comp_attdate.Enabled = False
  1621. comp_attdate.BackColor = &H80000012
  1622. comp_attby.Enabled = False
  1623. comp_attby.BackColor = &H80000012
  1624. comp_cause.Enabled = False
  1625. comp_cause.BackColor = &H80000012
  1626. comp_action.Enabled = False
  1627. comp_action.BackColor = &H80000012
  1628. End Sub
  1629. Private Sub comp_bottom_Click(Index As Integer)
  1630. ctr = 1
  1631. prodinstfrm.setcomptempcom
  1632. If prodinstfrm.comptemprs.RecordCount > 0 Then
  1633.   comp_save = True
  1634.   If recvalidated = 0 Then
  1635.     Exit Sub
  1636.   Else
  1637.     recvalidated = 0
  1638.   End If
  1639.   comp_custph1.SetFocus
  1640.   prodinstfrm.setcomptempcom
  1641.   prodinstfrm.comptemprs.MoveFirst
  1642.   comp_date.Text = prodinstfrm.comptemprs.Fields(1)
  1643.   showrecords1
  1644. End If
  1645. End Sub
  1646. Private Sub comp_delete_Click()
  1647. confirmdelete = MsgBox("Are You Sure You Want To Delete This Record", vbYesNo)
  1648. If confirmdelete = vbYes Then
  1649.     prodinstfrm.custcaredb.Execute ("delete * from complaints where comp_custph1 ='" & comp_custph1 & "' and cstr(comp_date)='" & CStr(comp_date) & "'")
  1650.     prodinstfrm.custcaredb.Execute ("delete * from complaintstemp")
  1651.     prodinstfrm.custcaredb.Execute ("insert into complaintstemp select * from complaints where comp_custph1='" & comp_custph1 & "'")
  1652.     prodinstfrm.setcompcom
  1653.     prodinstfrm.setcomptempcom
  1654.  
  1655.     If prodinstfrm.comptemprs.RecordCount > 0 Then
  1656.         prodinstfrm.comptemprs.MoveFirst
  1657.         comp_custph1.SetFocus
  1658.         comp_custph1 = prodinstfrm.comprs.Fields(0)
  1659.         comp_date = prodinstfrm.comptemprs.Fields(1)
  1660.         showrecords1
  1661.         comp_data.Refresh
  1662.     ElseIf prodinstfrm.comprs.RecordCount > 0 Then
  1663.         comp_custph1 = prodinstfrm.comprs.Fields(0)
  1664.         comp_date = prodinstfrm.comprs.Fields(1)
  1665.         comp_custph1.SetFocus
  1666.         mastershow
  1667.     Else
  1668.         compinsert = 1
  1669.         blankrecords
  1670.         comp_date = Date
  1671.         prodinstfrm.setcomptempcom
  1672.         comp_data.Refresh
  1673.         comp_delete.Enabled = False
  1674.         comp_query.Enabled = False
  1675.     End If
  1676. End If
  1677. End Sub
  1678. Private Sub comp_previous_Click()
  1679. ctr = 1
  1680. If prodinstfrm.comptemprs.RecordCount > 0 Then
  1681.   comp_save = True
  1682.   If recvalidated = 0 Then
  1683.     Exit Sub
  1684.   Else
  1685.     recvalidated = 0
  1686.   End If
  1687.   prodinstfrm.setcomptempcom
  1688.   prodinstfrm.comptemprs.Filter = "comp_custph1='" & comp_custph1 & " 'and comp_date='" & CDate(comp_date) & "'"
  1689.   prodinstfrm.setcomptempcom
  1690.   prodinstfrm.comptemprs.MoveNext
  1691.   If prodinstfrm.comptemprs.EOF Then
  1692.     prodinstfrm.comptemprs.MovePrevious
  1693.   End If
  1694.   
  1695.   comp_date.Text = prodinstfrm.comptemprs.Fields(1)
  1696.   showrecords1
  1697.   comp_custph1.SetFocus
  1698. End If
  1699. End Sub
  1700. Private Sub comp_query_Click()
  1701. compqueryfrm.Top = 1000
  1702. compqueryfrm.Left = 1000
  1703. compqueryfrm.Height = 3200
  1704. compqueryfrm.Width = 7500
  1705. compqueryfrm.Show
  1706. End Sub
  1707. Private Sub comp_save_Click()
  1708.   'validating data
  1709.   If comp_custph1.Text = "" Then
  1710.     MsgBox ("Phone No Cannot Be Empty")
  1711.     comp_custph1.SetFocus
  1712.     Exit Sub
  1713.   End If
  1714.   
  1715.   If comp_date.Text = "" Or Not IsDate(comp_date) Then
  1716.     MsgBox ("Please Enter Valid Complaint Date")
  1717.     comp_date.SetFocus
  1718.     Exit Sub
  1719.   End If
  1720.   
  1721.   If comp_desc.Text = "" Then
  1722.     MsgBox ("Description Cannot Be Empty")
  1723.     comp_desc.SetFocus
  1724.     Exit Sub
  1725.   End If
  1726.  
  1727.  If comp_madeby.Text = "" Then
  1728.     MsgBox ("Complaint Made By Cannot Be Empty")
  1729.     comp_madeby.SetFocus
  1730.     Exit Sub
  1731.   End If
  1732.  
  1733.  If comp_madeby.Text = "" Then
  1734.     MsgBox ("Complaint Made By Cannot Be Empty")
  1735.     comp_madeby.SetFocus
  1736.     Exit Sub
  1737.  End If
  1738.  
  1739.  If comp_no.Text = "" Then
  1740.     MsgBox ("Complaint No By Cannot Be Empty")
  1741.     comp_no.SetFocus
  1742.     Exit Sub
  1743.  End If
  1744.   
  1745.   If comp_status.Text = "" Then
  1746.     MsgBox ("Complaint Status Cannot Be Empty")
  1747.     comp_status.SetFocus
  1748.     Exit Sub
  1749.   End If
  1750.    
  1751.   If comp_status.Text = "Completed" Then
  1752.     If comp_attdate.Text = "" Or comp_attdate.Text = "0" Then
  1753.         MsgBox ("Complaint Attended On Date Cannot Be Empty")
  1754.         comp_attdate.SetFocus
  1755.         Exit Sub
  1756.     End If
  1757.     If CDate(comp_attdate.Text) < comp_date.Text Then
  1758.         MsgBox ("Complaint Attended On Date Should Be Greater Than Complaint Date.")
  1759.         comp_attdate.SetFocus
  1760.         Exit Sub
  1761.     End If
  1762.     If comp_attby.Text = "" Then
  1763.         MsgBox ("Complaint Attended By Cannot Be Empty")
  1764.         comp_attby.SetFocus
  1765.         Exit Sub
  1766.     End If
  1767.     If comp_cause.Text = "" Then
  1768.         MsgBox ("Complaint Cause Cannot Be Empty")
  1769.         comp_cause.SetFocus
  1770.         Exit Sub
  1771.     End If
  1772.     If comp_action.Text = "" Then
  1773.         MsgBox ("Action Taken Cannot Be Empty")
  1774.         comp_action.SetFocus
  1775.         Exit Sub
  1776.     End If
  1777.   End If
  1778.    
  1779.  'checking for duplicate complaint no
  1780.   prodinstfrm.setcompcom
  1781.   If prodinstfrm.comprs.RecordCount > 0 Then
  1782.     prodinstfrm.comprs.MoveFirst
  1783.     Do While Not prodinstfrm.comprs.EOF
  1784.         If (prodinstfrm.comprs.Fields(0) = Val(comp_custph1) And prodinstfrm.comprs.Fields(1) <> comp_date) Or (prodinstfrm.comprs.Fields(0) <> Val(comp_custph1)) Then
  1785.             If prodinstfrm.comprs.Fields(8) = Val(comp_no) Then
  1786.                 MsgBox ("This Complaint No Already Exists")
  1787.                 comp_no.SetFocus
  1788.                 Exit Sub
  1789.             End If
  1790.         End If
  1791.         prodinstfrm.comprs.MoveNext
  1792.     Loop
  1793.   End If
  1794.   
  1795.   'transfer complaintstemp data to complaints table
  1796.   prodinstfrm.custcaredb.Execute ("delete * from complaints where comp_custph1='" & comp_custph1.Text & "'")
  1797.   prodinstfrm.custcaredb.Execute ("insert into complaints select * from complaintstemp where comp_custph1='" & comp_custph1.Text & "'")
  1798.   
  1799.   'transfer complaints data to complaintstemp table
  1800.   prodinstfrm.custcaredb.Execute ("delete * from complaintstemp")
  1801.   prodinstfrm.custcaredb.Execute ("insert into complaintstemp select * from complaints where comp_custph1='" & comp_custph1.Text & "'")
  1802.   
  1803.   compinsert = 0
  1804.   prodinstfrm.setcomptempcom
  1805.   comp_data.Refresh
  1806.   
  1807.   recvalidated = 1
  1808.   ctr = 1
  1809.   comp_delete.Enabled = True
  1810.   comp_query.Enabled = True
  1811.   comp_custph1.SetFocus
  1812. End Sub
  1813. Private Sub comp_top_Click()
  1814. ctr = 1
  1815. prodinstfrm.setcomptempcom
  1816. If prodinstfrm.comptemprs.RecordCount > 0 Then
  1817.   comp_save = True
  1818.   If recvalidated = 0 Then
  1819.     Exit Sub
  1820.   Else
  1821.     recvalidated = 0
  1822.   End If
  1823.   comp_custph1.SetFocus
  1824.   prodinstfrm.comptemprs.MoveLast
  1825.   comp_date.Text = prodinstfrm.comptemprs.Fields(1)
  1826.   showrecords1
  1827. End If
  1828. End Sub
  1829. Private Sub comp_undo_Click()
  1830.   undoclick = 1
  1831.   comp_undo.Enabled = False
  1832.   comp_delete.Enabled = True
  1833.   comp_query.Enabled = True
  1834.   comp_top.Enabled = True
  1835.   comp_bottom(0).Enabled = True
  1836.   comp_previous.Enabled = True
  1837.   comp_next.Enabled = True
  1838.   prodinstfrm.setcompcom
  1839.   If prodinstfrm.comprs.RecordCount > 0 Then
  1840.     prodinstfrm.comprs.Filter = "comp_custph1<>'" & comp_custph1.Text & "'"
  1841.     showrecords
  1842.     comp_custph1.Text = prodinstfrm.comprs.Fields(0)
  1843.     comp_custph1.SetFocus
  1844.     prodinstfrm.custcaredb.Execute ("Insert into complaintstemp select * from complaints where comp_custph1='" & comp_custph1.Text & "'")
  1845.     prodinstfrm.setcomptempcom
  1846.     prodinstfrm.comptemprs.MoveFirst
  1847.     comp_data.Refresh
  1848.     showrecords1
  1849.   End If
  1850. End Sub
  1851. Public Sub mastershow()
  1852. prodinstfrm.custrs.Filter = "cust_ph1='" & comp_custph1 & "'"
  1853.  
  1854. If prodinstfrm.custrs.EOF = False And prodinstfrm.custrs.BOF = False Then
  1855.     showrecords
  1856.     fillprodicno
  1857. Else
  1858.     lblcomp_custname.Caption = ""
  1859.     lblcomp_custadd.Caption = ""
  1860.     lblcomp_custcity.Caption = ""
  1861.     lblcomp_custstate.Caption = ""
  1862.     lblcomp_custpin.Caption = 0
  1863.     lblcomp_custph2.Caption = 0
  1864.     lblcomp_fax.Caption = 0
  1865.     lblcomp_custemail.Caption = ""
  1866.     lblcomp_landmark.Caption = ""
  1867. End If
  1868.  
  1869. prodinstfrm.custcaredb.Execute ("delete * from complaintstemp")
  1870. prodinstfrm.setcompcom
  1871.  
  1872. If prodinstfrm.comprs.RecordCount > 0 Then
  1873.     If newcomplaint = 2 Then
  1874.         prodinstfrm.comprs.Filter = "comp_custph1='" & curcustph1 & "' and comp_date='" & curcustdate & " '"
  1875.     Else
  1876.         prodinstfrm.comprs.Filter = "comp_custph1='" & comp_custph1 & "'"
  1877.     End If
  1878.  
  1879.     If prodinstfrm.comprs.EOF = False And prodinstfrm.comprs.BOF = False Then
  1880.         comp_undo.Enabled = False
  1881.         comp_delete.Enabled = True
  1882.         comp_query.Enabled = True
  1883.         comp_top.Enabled = True
  1884.         comp_bottom(0).Enabled = True
  1885.         comp_previous.Enabled = True
  1886.         comp_next.Enabled = True
  1887.         prodinstfrm.custcaredb.Execute ("Insert into complaintstemp select * from complaints where comp_custph1='" & comp_custph1 & "'")
  1888.         prodinstfrm.setcomptempcom
  1889.         comp_date = prodinstfrm.comptemprs.Fields(1)
  1890.         If prodinstfrm.comptemprs.RecordCount > 0 Then
  1891.             If newcomplaint = 2 Then
  1892.                prodinstfrm.comptemprs.Filter = "comp_custph1='" & curcustph1 & "' and comp_date='" & curcustdate & " '"
  1893.             Else
  1894.                 prodinstfrm.comptemprs.MoveFirst
  1895.             End If
  1896.                 showrecords1
  1897.         End If
  1898.         comp_data.Refresh
  1899.     Else: blankrecords
  1900.         comp_undo.Enabled = True
  1901.         comp_delete.Enabled = False
  1902.         comp_query.Enabled = False
  1903.         comp_top.Enabled = False
  1904.         comp_bottom(0).Enabled = False
  1905.         comp_previous.Enabled = False
  1906.         comp_next.Enabled = False
  1907.         comp_data.Refresh
  1908.         compinsert = 1
  1909.     End If
  1910. End If
  1911. End Sub
  1912. Public Sub complaints_wchange()
  1913. If Trim(comp_custph1.Text) <> "" And IsDate(comp_date) And comp_madeby.Text <> "" Then
  1914.     If compinsert = 1 Then
  1915.         prodinstfrm.custcaredb.Execute ("insert into complaintstemp values ('" & comp_custph1 & "','" & comp_date & "','" & comp_desc & "','" & comp_attdate & "','" & comp_attby & "','" & comp_cause & "','" & comp_action & "','" & comp_status & "','" & comp_no & "','" & comp_madeby & "','" & comp_prdicno1 & "')")
  1916.         compinsert = 0
  1917.     Else
  1918.         prodinstfrm.custcaredb.Execute ("update complaintstemp set comp_desc='" & comp_desc.Text & "' where complaintstemp.comp_custph1='" & comp_custph1 & "' and cstr(complaintstemp.comp_date)='" & CStr(comp_date) & "'")
  1919.         prodinstfrm.custcaredb.Execute ("update complaintstemp set comp_attdate='" & comp_attdate.Text & "' where complaintstemp.comp_custph1='" & comp_custph1 & "' and cstr(complaintstemp.comp_date)='" & CStr(comp_date) & "'")
  1920.         prodinstfrm.custcaredb.Execute ("update complaintstemp set comp_attby='" & comp_attby.Text & "' where complaintstemp.comp_custph1='" & comp_custph1 & "' and cstr(complaintstemp.comp_date)='" & CStr(comp_date) & "'")
  1921.         prodinstfrm.custcaredb.Execute ("update complaintstemp set comp_cause='" & comp_cause.Text & "' where complaintstemp.comp_custph1='" & comp_custph1 & "' and cstr(complaintstemp.comp_date)='" & CStr(comp_date) & "'")
  1922.         prodinstfrm.custcaredb.Execute ("update complaintstemp set comp_action='" & comp_action.Text & "' where complaintstemp.comp_custph1='" & comp_custph1 & "' and cstr(complaintstemp.comp_date)='" & CStr(comp_date) & "'")
  1923.         prodinstfrm.custcaredb.Execute ("update complaintstemp set comp_status='" & Trim(comp_status.Text) & "' where complaintstemp.comp_custph1='" & comp_custph1 & "' and cstr(complaintstemp.comp_date)='" & CStr(comp_date) & "'")
  1924.         prodinstfrm.custcaredb.Execute ("update complaintstemp set comp_no='" & Trim(comp_no.Text) & "' where complaintstemp.comp_custph1='" & comp_custph1 & "' and cstr(complaintstemp.comp_date)='" & CStr(comp_date) & "'")
  1925.         prodinstfrm.custcaredb.Execute ("update complaintstemp set comp_madeby='" & Trim(comp_madeby.Text) & "' where complaintstemp.comp_custph1='" & comp_custph1 & "' and cstr(complaintstemp.comp_date)='" & CStr(comp_date) & "'")
  1926.         prodinstfrm.custcaredb.Execute ("update complaintstemp set comp_prdicno='" & Trim(comp_prdicno1.Text) & "' where complaintstemp.comp_custph1='" & comp_custph1 & "' and cstr(complaintstemp.comp_date)='" & CStr(comp_date) & "'")
  1927.     End If
  1928. End If
  1929. End Sub
  1930. Public Sub showrecords1()
  1931. If prodinstfrm.comptemprs.RecordCount > 0 Then
  1932.     If prodinstfrm.comptemprs.Fields(9) <> "" Then
  1933.         comp_madeby = prodinstfrm.comptemprs.Fields(9)
  1934.     End If
  1935.     If prodinstfrm.comptemprs.Fields(10) <> "" Then
  1936.         comp_prdicno1 = prodinstfrm.comptemprs.Fields(10)
  1937.     End If
  1938.     If prodinstfrm.comptemprs.Fields(8) <> "" Then
  1939.         comp_no.Text = prodinstfrm.comptemprs.Fields(8)
  1940.     End If
  1941.     If prodinstfrm.comptemprs.Fields(2) <> "" Then
  1942.         comp_desc = prodinstfrm.comptemprs.Fields(2)
  1943.     End If
  1944.     If prodinstfrm.comptemprs.Fields(7) <> "" Then
  1945.         comp_status.Text = prodinstfrm.comptemprs.Fields(7)
  1946.     End If
  1947.     If prodinstfrm.comptemprs.Fields(3) <> "" Then
  1948.         comp_attdate.Text = prodinstfrm.comptemprs.Fields(3)
  1949.     End If
  1950.     If prodinstfrm.comptemprs.Fields(4) <> "" Then
  1951.         comp_attby.Text = prodinstfrm.comptemprs.Fields(4)
  1952.     End If
  1953.     If prodinstfrm.comptemprs.Fields(5) <> "" Then
  1954.         comp_cause.Text = prodinstfrm.comptemprs.Fields(5)
  1955.     End If
  1956.     If prodinstfrm.comptemprs.Fields(6) <> "" Then
  1957.         comp_action.Text = prodinstfrm.comptemprs.Fields(6)
  1958.     End If
  1959.     If Trim(comp_status) = "Completed" Then
  1960.         comp_attdate.Enabled = True
  1961.         comp_attdate.BackColor = &HFFFFFF
  1962.         comp_attby.Enabled = True
  1963.         comp_attby.BackColor = &HFFFFFF
  1964.         comp_cause.Enabled = True
  1965.         comp_cause.BackColor = &HFFFFFF
  1966.         comp_action.Enabled = True
  1967.         comp_action.BackColor = &HFFFFFF
  1968.         Else
  1969.         comp_attdate.Enabled = False
  1970.         comp_attdate.BackColor = &H80000012
  1971.         comp_attby.Enabled = False
  1972.         comp_attby.BackColor = &H80000012
  1973.         comp_cause.Enabled = False
  1974.         comp_cause.BackColor = &H80000012
  1975.         comp_action.Enabled = False
  1976.         comp_action.BackColor = &H80000012
  1977.     End If
  1978. End If
  1979. End Sub
  1980. Public Sub detailshow()
  1981. If comp_custph1 <> "" And IsDate(comp_date) Then
  1982.     prodinstfrm.setcomptempcom
  1983.     prodinstfrm.comptemprs.Filter = "comp_custph1='" & comp_custph1.Text & "' and comp_date='" & CDate(comp_date.Text) & "'"
  1984.     If prodinstfrm.comptemprs.EOF = False And prodinstfrm.comptemprs.BOF = False Then
  1985.         compinsert = 0
  1986.         comp_undo.Enabled = False
  1987.         showrecords1
  1988.         comp_undo.Enabled = False
  1989.         comp_delete.Enabled = True
  1990.         comp_query.Enabled = True
  1991.         comp_top.Enabled = True
  1992.         comp_bottom(0).Enabled = True
  1993.         comp_previous.Enabled = True
  1994.         comp_next.Enabled = True
  1995.         Else
  1996.         compinsert = 1
  1997.         comp_undo.Enabled = True
  1998.         comp_delete.Enabled = False
  1999.         comp_query.Enabled = False
  2000.         comp_top.Enabled = False
  2001.         comp_bottom(0).Enabled = False
  2002.         comp_previous.Enabled = False
  2003.         comp_next.Enabled = False
  2004.         blankrecords
  2005.     End If
  2006. End If
  2007. End Sub
  2008. Public Sub gridchange()
  2009. If comp_grid.Columns(0) <> "" Then
  2010.     prodinstfrm.setcomptempcom
  2011.     prodinstfrm.comptemprs.Filter = "comp_custph1='" & comp_custph1 & "'and comp_date='" & comp_grid.Columns(1) & "'"
  2012.     If prodinstfrm.comptemprs.EOF = False And prodinstfrm.comptemprs.BOF = False Then
  2013.         comp_date = comp_grid.Columns(1)
  2014.         showrecords1
  2015.     End If
  2016. End If
  2017. End Sub
  2018. Public Sub showrecords()
  2019. lblcomp_custname.Caption = prodinstfrm.custrs.Fields(0)
  2020. lblcomp_custadd.Caption = prodinstfrm.custrs.Fields(1)
  2021. lblcomp_custcity.Caption = prodinstfrm.custrs.Fields(2)
  2022. lblcomp_custstate.Caption = prodinstfrm.custrs.Fields(3)
  2023. lblcomp_custpin.Caption = prodinstfrm.custrs.Fields(4)
  2024. lblcomp_custph2.Caption = prodinstfrm.custrs.Fields(6)
  2025. lblcomp_fax.Caption = prodinstfrm.custrs.Fields(7)
  2026. lblcomp_custemail.Caption = prodinstfrm.custrs.Fields(8)
  2027. lblcomp_landmark.Caption = prodinstfrm.custrs.Fields(9)
  2028. End Sub
  2029.  
  2030. Private Sub Show_grid_Click()
  2031. If comp_grid.Visible = False Then
  2032.     comp_grid.Visible = True
  2033.     Show_grid.Caption = "&Hide Grid"
  2034.     
  2035.     Else
  2036.     comp_grid.Visible = False
  2037.     Show_grid.Caption = "Show &All Complaints"
  2038. End If
  2039. End Sub
  2040. Private Sub fillprodicno()
  2041. comp_prdicno1.Clear
  2042. prodinstfrm.setprodcom
  2043. If prodinstfrm.prodrs.RecordCount > 0 Then
  2044.     prodinstfrm.prodrs.MoveFirst
  2045.     Do While Not prodinstfrm.prodrs.EOF
  2046.         If comp_custph1 = prodinstfrm.prodrs.Fields(0) Then
  2047.             comp_prdicno1.AddItem (prodinstfrm.prodrs.Fields(5))
  2048.         End If
  2049.         prodinstfrm.prodrs.MoveNext
  2050.     Loop
  2051.     comp_prdicno1.Text = comp_prdicno1.List(0)
  2052. End If
  2053. End Sub
  2054. Public Sub showprodinfo()
  2055. If comp_prdicno1.ListCount > 0 Then
  2056.     comp_prodinfo.Visible = True
  2057.     comp_prodinfo.Clear
  2058.     prodinstfrm.setprodcom
  2059.     prodinstfrm.prodrs.MoveFirst
  2060.     Do While Not prodinstfrm.prodrs.EOF
  2061.     If prodinstfrm.prodrs.Fields(0) = comp_custph1.Text And prodinstfrm.prodrs.Fields(5) = comp_prdicno1.Text Then
  2062.         comp_prodinfo.AddItem ("PRODUCT NO:                  " + prodinstfrm.prodrs.Fields(1))
  2063.         comp_prodinfo.AddItem ("PRODUCT NAME:               " + prodinstfrm.prodrs.Fields(2))
  2064.         comp_prodinfo.AddItem ("PRODUCT INSTALLED ON:  " + CStr(prodinstfrm.prodrs.Fields(3)))
  2065.         comp_prodinfo.AddItem ("PRODUCT INSTALLED BY:  " + prodinstfrm.prodrs.Fields(4))
  2066.     End If
  2067.     prodinstfrm.prodrs.MoveNext
  2068.     Loop
  2069. End If
  2070. End Sub
  2071.