home *** CD-ROM | disk | FTP | other *** search
/ Planet Source Code Jumbo …e CD Visual Basic 1 to 7 / 1_2002.ISO / Data / Zips / Super_Cale750974232002.psc / frmMain.frm (.txt) < prev    next >
Encoding:
Visual Basic Form  |  2002-04-23  |  34.0 KB  |  1,129 lines

  1. VERSION 5.00
  2. Begin VB.Form frmMain 
  3.    BorderStyle     =   1  'Fixed Single
  4.    Caption         =   "Calendar"
  5.    ClientHeight    =   6630
  6.    ClientLeft      =   45
  7.    ClientTop       =   615
  8.    ClientWidth     =   5655
  9.    Icon            =   "frmMain.frx":0000
  10.    LinkTopic       =   "Form1"
  11.    MaxButton       =   0   'False
  12.    MinButton       =   0   'False
  13.    ScaleHeight     =   442
  14.    ScaleMode       =   3  'P
  15.    ScaleWidth      =   377
  16.    StartUpPosition =   2  'CenterScreen
  17.    Begin VB.Timer tmrClock 
  18.       Interval        =   100
  19.       Left            =   4680
  20.       Top             =   4920
  21.    End
  22.    Begin VB.Frame fraReminders 
  23.       Caption         =   "Reminders"
  24.       Height          =   2895
  25.       Left            =   120
  26.       TabIndex        =   52
  27.       Top             =   3600
  28.       Width           =   5415
  29.       Begin VB.CommandButton cmdOp 
  30.          Caption         =   "Remove"
  31.          Enabled         =   0   'False
  32.          Height          =   375
  33.          Index           =   1
  34.          Left            =   1680
  35.          TabIndex        =   63
  36.          Top             =   2400
  37.          Width           =   855
  38.       End
  39.       Begin VB.CommandButton cmdOp 
  40.          Caption         =   "Rename"
  41.          Enabled         =   0   'False
  42.          Height          =   375
  43.          Index           =   0
  44.          Left            =   840
  45.          TabIndex        =   62
  46.          Top             =   2400
  47.          Width           =   855
  48.       End
  49.       Begin VB.CommandButton cmdMove 
  50.          DisabledPicture =   "frmMain.frx":030A
  51.          Enabled         =   0   'False
  52.          Height          =   375
  53.          Index           =   1
  54.          Left            =   480
  55.          MaskColor       =   &H00000000&
  56.          Picture         =   "frmMain.frx":0398
  57.          Style           =   1  'Graphical
  58.          TabIndex        =   61
  59.          Top             =   2400
  60.          UseMaskColor    =   -1  'True
  61.          Width           =   375
  62.       End
  63.       Begin VB.CommandButton cmdMove 
  64.          DisabledPicture =   "frmMain.frx":0426
  65.          Enabled         =   0   'False
  66.          Height          =   375
  67.          Index           =   0
  68.          Left            =   120
  69.          MaskColor       =   &H00000000&
  70.          Picture         =   "frmMain.frx":04B4
  71.          Style           =   1  'Graphical
  72.          TabIndex        =   60
  73.          Top             =   2400
  74.          UseMaskColor    =   -1  'True
  75.          Width           =   375
  76.       End
  77.       Begin VB.CommandButton cmdProperties 
  78.          Caption         =   "&Properties..."
  79.          Enabled         =   0   'False
  80.          Height          =   375
  81.          Left            =   2640
  82.          TabIndex        =   55
  83.          Top             =   2400
  84.          Width           =   1215
  85.       End
  86.       Begin VB.TextBox txtAppt 
  87.          BackColor       =   &H8000000F&
  88.          Height          =   1935
  89.          Left            =   2640
  90.          Locked          =   -1  'True
  91.          MultiLine       =   -1  'True
  92.          ScrollBars      =   3  'Both
  93.          TabIndex        =   54
  94.          Top             =   360
  95.          Width           =   2655
  96.       End
  97.       Begin VB.ListBox lstAppt 
  98.          Height          =   1905
  99.          IntegralHeight  =   0   'False
  100.          Left            =   120
  101.          TabIndex        =   53
  102.          Top             =   360
  103.          Width           =   2415
  104.       End
  105.       Begin VB.Label lblAlarm 
  106.          Alignment       =   2  'Center
  107.          Caption         =   "Alarm not set"
  108.          Height          =   255
  109.          Left            =   3960
  110.          TabIndex        =   56
  111.          Top             =   2520
  112.          Width           =   1335
  113.       End
  114.    End
  115.    Begin VB.Frame fraCalendar 
  116.       Caption         =   "Calendar"
  117.       Height          =   3375
  118.       Left            =   120
  119.       TabIndex        =   0
  120.       Top             =   120
  121.       Width           =   5415
  122.       Begin VB.PictureBox picClock 
  123.          Appearance      =   0  'Flat
  124.          AutoRedraw      =   -1  'True
  125.          BackColor       =   &H00FFFFFF&
  126.          DrawWidth       =   2
  127.          ForeColor       =   &H80000008&
  128.          Height          =   1455
  129.          Left            =   3840
  130.          ScaleHeight     =   1425
  131.          ScaleWidth      =   1425
  132.          TabIndex        =   58
  133.          Top             =   1440
  134.          Width           =   1455
  135.          Begin VB.Label lblPm 
  136.             AutoSize        =   -1  'True
  137.             BackStyle       =   0  'Transparent
  138.             Caption         =   "PM"
  139.             ForeColor       =   &H00C00000&
  140.             Height          =   195
  141.             Left            =   0
  142.             TabIndex        =   59
  143.             Top             =   0
  144.             Width           =   240
  145.          End
  146.          Begin VB.Line Clock 
  147.             BorderColor     =   &H000000FF&
  148.             Index           =   0
  149.             X1              =   600
  150.             X2              =   600
  151.             Y1              =   600
  152.             Y2              =   1320
  153.          End
  154.          Begin VB.Line Clock 
  155.             BorderColor     =   &H00000000&
  156.             BorderWidth     =   2
  157.             Index           =   1
  158.             X1              =   720
  159.             X2              =   720
  160.             Y1              =   600
  161.             Y2              =   1320
  162.          End
  163.          Begin VB.Line Clock 
  164.             BorderColor     =   &H00000000&
  165.             BorderWidth     =   2
  166.             Index           =   2
  167.             X1              =   840
  168.             X2              =   840
  169.             Y1              =   600
  170.             Y2              =   1320
  171.          End
  172.       End
  173.       Begin VB.ComboBox cmbMonth 
  174.          Height          =   315
  175.          ItemData        =   "frmMain.frx":0542
  176.          Left            =   3840
  177.          List            =   "frmMain.frx":056A
  178.          Style           =   2  'Dropdown List
  179.          TabIndex        =   1
  180.          Top             =   360
  181.          Width           =   1335
  182.       End
  183.       Begin VB.TextBox txtYear 
  184.          Height          =   285
  185.          Left            =   3840
  186.          TabIndex        =   2
  187.          Top             =   840
  188.          Width           =   1335
  189.       End
  190.       Begin VB.Label lblCompleteDay 
  191.          Height          =   255
  192.          Left            =   240
  193.          TabIndex        =   57
  194.          Top             =   3000
  195.          Width           =   4935
  196.       End
  197.       Begin VB.Label lblWeekDay 
  198.          Alignment       =   2  'Center
  199.          BackStyle       =   0  'Transparent
  200.          Caption         =   "Sun"
  201.          Height          =   195
  202.          Index           =   0
  203.          Left            =   360
  204.          TabIndex        =   51
  205.          Top             =   360
  206.          Width           =   405
  207.       End
  208.       Begin VB.Label lblWeekDay 
  209.          Alignment       =   2  'Center
  210.          BackStyle       =   0  'Transparent
  211.          Caption         =   "Mon"
  212.          Height          =   195
  213.          Index           =   1
  214.          Left            =   840
  215.          TabIndex        =   50
  216.          Top             =   360
  217.          Width           =   375
  218.       End
  219.       Begin VB.Label lblWeekDay 
  220.          Alignment       =   2  'Center
  221.          BackStyle       =   0  'Transparent
  222.          Caption         =   "Tue"
  223.          Height          =   195
  224.          Index           =   2
  225.          Left            =   1320
  226.          TabIndex        =   49
  227.          Top             =   360
  228.          Width           =   405
  229.       End
  230.       Begin VB.Label lblWeekDay 
  231.          Alignment       =   2  'Center
  232.          BackStyle       =   0  'Transparent
  233.          Caption         =   "Wed"
  234.          Height          =   195
  235.          Index           =   3
  236.          Left            =   1800
  237.          TabIndex        =   48
  238.          Top             =   360
  239.          Width           =   405
  240.       End
  241.       Begin VB.Label lblWeekDay 
  242.          Alignment       =   2  'Center
  243.          BackStyle       =   0  'Transparent
  244.          Caption         =   "Thu"
  245.          Height          =   195
  246.          Index           =   4
  247.          Left            =   2280
  248.          TabIndex        =   47
  249.          Top             =   360
  250.          Width           =   405
  251.       End
  252.       Begin VB.Label lblWeekDay 
  253.          Alignment       =   2  'Center
  254.          BackStyle       =   0  'Transparent
  255.          Caption         =   "Fri"
  256.          Height          =   195
  257.          Index           =   5
  258.          Left            =   2760
  259.          TabIndex        =   46
  260.          Top             =   360
  261.          Width           =   405
  262.       End
  263.       Begin VB.Label lblWeekDay 
  264.          Alignment       =   2  'Center
  265.          BackStyle       =   0  'Transparent
  266.          Caption         =   "Sat"
  267.          Height          =   195
  268.          Index           =   6
  269.          Left            =   3240
  270.          TabIndex        =   45
  271.          Top             =   360
  272.          Width           =   405
  273.       End
  274.       Begin VB.Label lblDay 
  275.          Alignment       =   2  'Center
  276.          BackColor       =   &H00FFFFFF&
  277.          Caption         =   "X"
  278.          Height          =   195
  279.          Index           =   7
  280.          Left            =   3240
  281.          TabIndex        =   44
  282.          Top             =   720
  283.          Width           =   405
  284.       End
  285.       Begin VB.Label lblDay 
  286.          Alignment       =   2  'Center
  287.          BackColor       =   &H00FFFFFF&
  288.          Caption         =   "X"
  289.          Height          =   195
  290.          Index           =   6
  291.          Left            =   2760
  292.          TabIndex        =   43
  293.          Top             =   720
  294.          Width           =   405
  295.       End
  296.       Begin VB.Label lblDay 
  297.          Alignment       =   2  'Center
  298.          BackColor       =   &H00FFFFFF&
  299.          Caption         =   "X"
  300.          Height          =   195
  301.          Index           =   5
  302.          Left            =   2280
  303.          TabIndex        =   42
  304.          Top             =   720
  305.          Width           =   405
  306.       End
  307.       Begin VB.Label lblDay 
  308.          Alignment       =   2  'Center
  309.          BackColor       =   &H00FFFFFF&
  310.          Caption         =   "X"
  311.          Height          =   195
  312.          Index           =   4
  313.          Left            =   1800
  314.          TabIndex        =   41
  315.          Top             =   720
  316.          Width           =   405
  317.       End
  318.       Begin VB.Label lblDay 
  319.          Alignment       =   2  'Center
  320.          BackColor       =   &H00FFFFFF&
  321.          Caption         =   "X"
  322.          Height          =   195
  323.          Index           =   3
  324.          Left            =   1320
  325.          TabIndex        =   40
  326.          Top             =   720
  327.          Width           =   405
  328.       End
  329.       Begin VB.Label lblDay 
  330.          Alignment       =   2  'Center
  331.          BackColor       =   &H00FFFFFF&
  332.          Caption         =   "X"
  333.          Height          =   195
  334.          Index           =   2
  335.          Left            =   840
  336.          TabIndex        =   39
  337.          Top             =   720
  338.          Width           =   375
  339.       End
  340.       Begin VB.Label lblDay 
  341.          Alignment       =   2  'Center
  342.          BackColor       =   &H00FFFFFF&
  343.          Caption         =   "X"
  344.          Height          =   195
  345.          Index           =   1
  346.          Left            =   360
  347.          TabIndex        =   38
  348.          Top             =   720
  349.          Width           =   405
  350.       End
  351.       Begin VB.Label lblDay 
  352.          Alignment       =   2  'Center
  353.          BackColor       =   &H00FFFFFF&
  354.          Caption         =   "X"
  355.          Height          =   195
  356.          Index           =   14
  357.          Left            =   3240
  358.          TabIndex        =   37
  359.          Top             =   1080
  360.          Width           =   405
  361.       End
  362.       Begin VB.Label lblDay 
  363.          Alignment       =   2  'Center
  364.          BackColor       =   &H00FFFFFF&
  365.          Caption         =   "X"
  366.          Height          =   195
  367.          Index           =   13
  368.          Left            =   2760
  369.          TabIndex        =   36
  370.          Top             =   1080
  371.          Width           =   405
  372.       End
  373.       Begin VB.Label lblDay 
  374.          Alignment       =   2  'Center
  375.          BackColor       =   &H00FFFFFF&
  376.          Caption         =   "X"
  377.          Height          =   195
  378.          Index           =   12
  379.          Left            =   2280
  380.          TabIndex        =   35
  381.          Top             =   1080
  382.          Width           =   405
  383.       End
  384.       Begin VB.Label lblDay 
  385.          Alignment       =   2  'Center
  386.          BackColor       =   &H00FFFFFF&
  387.          Caption         =   "X"
  388.          Height          =   195
  389.          Index           =   11
  390.          Left            =   1800
  391.          TabIndex        =   34
  392.          Top             =   1080
  393.          Width           =   405
  394.       End
  395.       Begin VB.Label lblDay 
  396.          Alignment       =   2  'Center
  397.          BackColor       =   &H00FFFFFF&
  398.          Caption         =   "X"
  399.          Height          =   195
  400.          Index           =   10
  401.          Left            =   1320
  402.          TabIndex        =   33
  403.          Top             =   1080
  404.          Width           =   405
  405.       End
  406.       Begin VB.Label lblDay 
  407.          Alignment       =   2  'Center
  408.          BackColor       =   &H00FFFFFF&
  409.          Caption         =   "X"
  410.          Height          =   195
  411.          Index           =   9
  412.          Left            =   840
  413.          TabIndex        =   32
  414.          Top             =   1080
  415.          Width           =   375
  416.       End
  417.       Begin VB.Label lblDay 
  418.          Alignment       =   2  'Center
  419.          BackColor       =   &H00FFFFFF&
  420.          Caption         =   "X"
  421.          Height          =   195
  422.          Index           =   8
  423.          Left            =   360
  424.          TabIndex        =   31
  425.          Top             =   1080
  426.          Width           =   405
  427.       End
  428.       Begin VB.Label lblDay 
  429.          Alignment       =   2  'Center
  430.          BackColor       =   &H00FFFFFF&
  431.          Caption         =   "X"
  432.          Height          =   195
  433.          Index           =   21
  434.          Left            =   3240
  435.          TabIndex        =   30
  436.          Top             =   1440
  437.          Width           =   405
  438.       End
  439.       Begin VB.Label lblDay 
  440.          Alignment       =   2  'Center
  441.          BackColor       =   &H00FFFFFF&
  442.          Caption         =   "X"
  443.          Height          =   195
  444.          Index           =   20
  445.          Left            =   2760
  446.          TabIndex        =   29
  447.          Top             =   1440
  448.          Width           =   405
  449.       End
  450.       Begin VB.Label lblDay 
  451.          Alignment       =   2  'Center
  452.          BackColor       =   &H00FFFFFF&
  453.          Caption         =   "X"
  454.          Height          =   195
  455.          Index           =   19
  456.          Left            =   2280
  457.          TabIndex        =   28
  458.          Top             =   1440
  459.          Width           =   405
  460.       End
  461.       Begin VB.Label lblDay 
  462.          Alignment       =   2  'Center
  463.          BackColor       =   &H00FFFFFF&
  464.          Caption         =   "X"
  465.          Height          =   195
  466.          Index           =   18
  467.          Left            =   1800
  468.          TabIndex        =   27
  469.          Top             =   1440
  470.          Width           =   405
  471.       End
  472.       Begin VB.Label lblDay 
  473.          Alignment       =   2  'Center
  474.          BackColor       =   &H00FFFFFF&
  475.          Caption         =   "X"
  476.          Height          =   195
  477.          Index           =   17
  478.          Left            =   1320
  479.          TabIndex        =   26
  480.          Top             =   1440
  481.          Width           =   405
  482.       End
  483.       Begin VB.Label lblDay 
  484.          Alignment       =   2  'Center
  485.          BackColor       =   &H00FFFFFF&
  486.          Caption         =   "X"
  487.          Height          =   195
  488.          Index           =   16
  489.          Left            =   840
  490.          TabIndex        =   25
  491.          Top             =   1440
  492.          Width           =   375
  493.       End
  494.       Begin VB.Label lblDay 
  495.          Alignment       =   2  'Center
  496.          BackColor       =   &H00FFFFFF&
  497.          Caption         =   "X"
  498.          Height          =   195
  499.          Index           =   15
  500.          Left            =   360
  501.          TabIndex        =   24
  502.          Top             =   1440
  503.          Width           =   405
  504.       End
  505.       Begin VB.Label lblDay 
  506.          Alignment       =   2  'Center
  507.          BackColor       =   &H00FFFFFF&
  508.          Caption         =   "X"
  509.          Height          =   195
  510.          Index           =   28
  511.          Left            =   3240
  512.          TabIndex        =   23
  513.          Top             =   1800
  514.          Width           =   405
  515.       End
  516.       Begin VB.Label lblDay 
  517.          Alignment       =   2  'Center
  518.          BackColor       =   &H00FFFFFF&
  519.          Caption         =   "X"
  520.          Height          =   195
  521.          Index           =   27
  522.          Left            =   2760
  523.          TabIndex        =   22
  524.          Top             =   1800
  525.          Width           =   405
  526.       End
  527.       Begin VB.Label lblDay 
  528.          Alignment       =   2  'Center
  529.          BackColor       =   &H00FFFFFF&
  530.          Caption         =   "X"
  531.          Height          =   195
  532.          Index           =   26
  533.          Left            =   2280
  534.          TabIndex        =   21
  535.          Top             =   1800
  536.          Width           =   405
  537.       End
  538.       Begin VB.Label lblDay 
  539.          Alignment       =   2  'Center
  540.          BackColor       =   &H00FFFFFF&
  541.          Caption         =   "X"
  542.          Height          =   195
  543.          Index           =   25
  544.          Left            =   1800
  545.          TabIndex        =   20
  546.          Top             =   1800
  547.          Width           =   405
  548.       End
  549.       Begin VB.Label lblDay 
  550.          Alignment       =   2  'Center
  551.          BackColor       =   &H00FFFFFF&
  552.          Caption         =   "X"
  553.          Height          =   195
  554.          Index           =   24
  555.          Left            =   1320
  556.          TabIndex        =   19
  557.          Top             =   1800
  558.          Width           =   405
  559.       End
  560.       Begin VB.Label lblDay 
  561.          Alignment       =   2  'Center
  562.          BackColor       =   &H00FFFFFF&
  563.          Caption         =   "X"
  564.          Height          =   195
  565.          Index           =   23
  566.          Left            =   840
  567.          TabIndex        =   18
  568.          Top             =   1800
  569.          Width           =   375
  570.       End
  571.       Begin VB.Label lblDay 
  572.          Alignment       =   2  'Center
  573.          BackColor       =   &H00FFFFFF&
  574.          Caption         =   "X"
  575.          Height          =   195
  576.          Index           =   22
  577.          Left            =   360
  578.          TabIndex        =   17
  579.          Top             =   1800
  580.          Width           =   405
  581.       End
  582.       Begin VB.Label lblDay 
  583.          Alignment       =   2  'Center
  584.          BackColor       =   &H00FFFFFF&
  585.          Caption         =   "X"
  586.          Height          =   195
  587.          Index           =   35
  588.          Left            =   3240
  589.          TabIndex        =   16
  590.          Top             =   2160
  591.          Width           =   405
  592.       End
  593.       Begin VB.Label lblDay 
  594.          Alignment       =   2  'Center
  595.          BackColor       =   &H00FFFFFF&
  596.          Caption         =   "X"
  597.          Height          =   195
  598.          Index           =   34
  599.          Left            =   2760
  600.          TabIndex        =   15
  601.          Top             =   2160
  602.          Width           =   405
  603.       End
  604.       Begin VB.Label lblDay 
  605.          Alignment       =   2  'Center
  606.          BackColor       =   &H00FFFFFF&
  607.          Caption         =   "X"
  608.          Height          =   195
  609.          Index           =   33
  610.          Left            =   2280
  611.          TabIndex        =   14
  612.          Top             =   2160
  613.          Width           =   405
  614.       End
  615.       Begin VB.Label lblDay 
  616.          Alignment       =   2  'Center
  617.          BackColor       =   &H00FFFFFF&
  618.          Caption         =   "X"
  619.          Height          =   195
  620.          Index           =   32
  621.          Left            =   1800
  622.          TabIndex        =   13
  623.          Top             =   2160
  624.          Width           =   405
  625.       End
  626.       Begin VB.Label lblDay 
  627.          Alignment       =   2  'Center
  628.          BackColor       =   &H00FFFFFF&
  629.          Caption         =   "X"
  630.          Height          =   195
  631.          Index           =   31
  632.          Left            =   1320
  633.          TabIndex        =   12
  634.          Top             =   2160
  635.          Width           =   405
  636.       End
  637.       Begin VB.Label lblDay 
  638.          Alignment       =   2  'Center
  639.          BackColor       =   &H00FFFFFF&
  640.          Caption         =   "X"
  641.          Height          =   195
  642.          Index           =   30
  643.          Left            =   840
  644.          TabIndex        =   11
  645.          Top             =   2160
  646.          Width           =   375
  647.       End
  648.       Begin VB.Label lblDay 
  649.          Alignment       =   2  'Center
  650.          BackColor       =   &H00FFFFFF&
  651.          Caption         =   "X"
  652.          Height          =   195
  653.          Index           =   29
  654.          Left            =   360
  655.          TabIndex        =   10
  656.          Top             =   2160
  657.          Width           =   405
  658.       End
  659.       Begin VB.Label lblDay 
  660.          Alignment       =   2  'Center
  661.          BackColor       =   &H00FFFFFF&
  662.          Caption         =   "X"
  663.          Height          =   195
  664.          Index           =   36
  665.          Left            =   360
  666.          TabIndex        =   9
  667.          Top             =   2520
  668.          Width           =   375
  669.       End
  670.       Begin VB.Label lblDay 
  671.          Alignment       =   2  'Center
  672.          BackColor       =   &H00FFFFFF&
  673.          Caption         =   "X"
  674.          Height          =   195
  675.          Index           =   37
  676.          Left            =   840
  677.          TabIndex        =   8
  678.          Top             =   2520
  679.          Width           =   405
  680.       End
  681.       Begin VB.Label lblDay 
  682.          Alignment       =   2  'Center
  683.          BackColor       =   &H00FFFFFF&
  684.          Caption         =   "X"
  685.          Height          =   195
  686.          Index           =   38
  687.          Left            =   1320
  688.          TabIndex        =   7
  689.          Top             =   2520
  690.          Width           =   405
  691.       End
  692.       Begin VB.Label lblDay 
  693.          Alignment       =   2  'Center
  694.          BackColor       =   &H00FFFFFF&
  695.          Caption         =   "X"
  696.          Height          =   195
  697.          Index           =   39
  698.          Left            =   1800
  699.          TabIndex        =   6
  700.          Top             =   2520
  701.          Width           =   405
  702.       End
  703.       Begin VB.Label lblDay 
  704.          Alignment       =   2  'Center
  705.          BackColor       =   &H00FFFFFF&
  706.          Caption         =   "X"
  707.          Height          =   195
  708.          Index           =   40
  709.          Left            =   2280
  710.          TabIndex        =   5
  711.          Top             =   2520
  712.          Width           =   405
  713.       End
  714.       Begin VB.Label lblDay 
  715.          Alignment       =   2  'Center
  716.          BackColor       =   &H00FFFFFF&
  717.          Caption         =   "X"
  718.          Height          =   195
  719.          Index           =   41
  720.          Left            =   2760
  721.          TabIndex        =   4
  722.          Top             =   2520
  723.          Width           =   405
  724.       End
  725.       Begin VB.Label lblDay 
  726.          Alignment       =   2  'Center
  727.          BackColor       =   &H00FFFFFF&
  728.          Caption         =   "X"
  729.          Height          =   195
  730.          Index           =   42
  731.          Left            =   3240
  732.          TabIndex        =   3
  733.          Top             =   2520
  734.          Width           =   405
  735.       End
  736.       Begin VB.Shape shaRectangle 
  737.          BackColor       =   &H00FFFFFF&
  738.          BackStyle       =   1  'Opaque
  739.          Height          =   2295
  740.          Left            =   240
  741.          Top             =   600
  742.          Width           =   3495
  743.       End
  744.       Begin VB.Shape shaWeekDays 
  745.          BackColor       =   &H00808080&
  746.          BackStyle       =   1  'Opaque
  747.          Height          =   255
  748.          Left            =   240
  749.          Top             =   360
  750.          Width           =   3495
  751.       End
  752.    End
  753.    Begin VB.Menu mnuOptions 
  754.       Caption         =   "&Options"
  755.       Begin VB.Menu mnuAppt 
  756.          Caption         =   "&Reminder"
  757.          Begin VB.Menu mnuAdd 
  758.             Caption         =   "&Add..."
  759.          End
  760.          Begin VB.Menu mnuRemove 
  761.             Caption         =   "&Remove"
  762.          End
  763.          Begin VB.Menu mnuRemoveAll 
  764.             Caption         =   "Remove a&ll"
  765.          End
  766.       End
  767.       Begin VB.Menu mnuStandBy 
  768.          Caption         =   "&StandBy mode"
  769.       End
  770.       Begin VB.Menu mnuExit 
  771.          Caption         =   "&Exit"
  772.       End
  773.    End
  774.    Begin VB.Menu mnuHelp 
  775.       Caption         =   "&Help"
  776.       Begin VB.Menu mnuAbout 
  777.          Caption         =   "&About..."
  778.       End
  779.    End
  780. Attribute VB_Name = "frmMain"
  781. Attribute VB_GlobalNameSpace = False
  782. Attribute VB_Creatable = False
  783. Attribute VB_PredeclaredId = True
  784. Attribute VB_Exposed = False
  785. Option Explicit
  786. Dim LockDown As Boolean
  787. Dim DiaSel As Long
  788. Const Pi As Double = 3.14159265358979
  789. Private Sub cmbMonth_Click()
  790.   LockDown = False
  791.   LoadCalendar Val(txtYear.Text), cmbMonth.ListIndex + 1, 1
  792.   LoadAppt
  793. End Sub
  794. Private Sub cmbMonth_DropDown()
  795.   LockDown = True
  796. End Sub
  797. Private Sub cmdMove_Click(Index As Integer)
  798.   Dim i As Long, Sel As Long, Sel1 As Long, Sel2 As Long
  799.   Dim Temp As REMINDER
  800.   With lstAppt
  801.     Sel = .ListIndex
  802.     If Sel = -1 Then Exit Sub
  803.     Sel2 = .ItemData(Sel)
  804.     Temp = Appt(Sel2)
  805.     If Index = 0 Then
  806.       If Sel = 0 Then Exit Sub
  807.       Sel = Sel - 1
  808.       Sel1 = .ItemData(Sel)
  809.       For i = Sel2 To Sel1 + 1 Step -1
  810.         Appt(i) = Appt(i - 1)
  811.       Next i
  812.       Appt(Sel1) = Temp
  813.     Else
  814.       If Sel = .ListCount - 1 Then Exit Sub
  815.       Sel = Sel + 1
  816.       Sel1 = .ItemData(Sel)
  817.       For i = Sel2 To Sel1 - 1
  818.         Appt(i) = Appt(i + 1)
  819.       Next i
  820.       Appt(Sel1) = Temp
  821.     End If
  822.     LoadAppt
  823.     .ListIndex = Sel
  824.   End With
  825. End Sub
  826. Private Sub cmdOp_Click(Index As Integer)
  827.   Dim Sel As Long
  828.   Dim Temp As String
  829.   With lstAppt
  830.     Sel = .ListIndex
  831.     If Sel = -1 Then Exit Sub
  832.     If Index = 0 Then
  833.       Temp = InputBox$("Rename reminder", , .List(Sel))
  834.       If Len(Temp) = 0 Then Exit Sub
  835.       .List(Sel) = Temp
  836.       Appt(.ItemData(Sel)).ApptName = Temp
  837.     Else
  838.       mnuRemove_Click
  839.     End If
  840.   End With
  841. End Sub
  842. Private Sub cmdProperties_Click()
  843.   Dim Sel As Long
  844.   With lstAppt
  845.     Sel = .ListIndex
  846.     If Sel = -1 Then Exit Sub
  847.     frmProperties.Show vbModal
  848.     LoadAppt
  849.     If .ListCount > Sel Then .ListIndex = Sel
  850.   End With
  851. End Sub
  852. Private Sub Form_Load()
  853.   Dim Current As Date
  854.   Current = Now()
  855.   DiaSel = Day(Current)
  856.   txtYear.Text = Year(Current)
  857.   cmbMonth.ListIndex = Month(Current) - 1
  858.   LoadCalendar 1, 1, 1, Current
  859.   LoadClock
  860.   Select Case UCase$(Command)
  861.     Case "RESIDENT"
  862.       mnuStandBy_Click
  863.       Exit Sub
  864.     Case ""
  865.     Case Else
  866.       MsgBox "Invalid command line argument", vbCritical, "Error"
  867.       End
  868.   End Select
  869.   Me.Show
  870. End Sub
  871. Private Sub LoadCalendar(ByVal A
  872. o As Long, ByVal Mes As Long, ByVal Dia As Long, Optional ByVal DateVal As Variant)
  873.   Dim DiaRel As Long, Init As Long, i As Long, HowMany As Long
  874.   If Not IsMissing(DateVal) Then
  875.     Dia = Day(DateVal)
  876.     Mes = Month(DateVal)
  877.     A
  878. o = Year(DateVal)
  879.   End If
  880.   ClearCalendar
  881.   DecolorCalendar
  882.   DiaRel = WeekDay(A
  883. o, Mes, Dia)
  884.   Init = Transform(DiaRel, Dia)
  885.   If Init = 6 Then Init = -1
  886.   HowMany = HowManyDays(Mes, A
  887.   If DiaSel > HowMany Then DiaSel = HowMany
  888.   For i = 1 To HowMany
  889.     With lblDay(Init + i + 1)
  890.       .Caption = Format(i)
  891.       If DiaSel = i Then .BackColor = vbRed
  892.     End With
  893.   Next i
  894.   MarkToday
  895. End Sub
  896. Private Sub ClearCalendar()
  897.   Dim i As Long
  898.   For i = 1 To lblDay.UBound
  899.     With lblDay(i)
  900.       If Len(.Caption) Then .Caption = ""
  901.     End With
  902.   Next i
  903. End Sub
  904. Private Sub DecolorCalendar()
  905.   Dim i As Long
  906.   For i = 1 To lblDay.UBound
  907.     With lblDay(i)
  908.       If .BackColor <> vbWhite Then .BackColor = vbWhite
  909.     End With
  910.   Next i
  911. End Sub
  912. Private Sub MarkToday()
  913.   Dim Current As Date
  914.   Dim i As Long, HoyDay As Long
  915.   Const Col = &H9090FF
  916.   Current = Now()
  917.   If LockDown Or Year(Current) <> Val(txtYear.Text) Or Month(Current) <> cmbMonth.ListIndex + 1 Then Exit Sub
  918.   HoyDay = Day(Current)
  919.   For i = 1 To lblDay.UBound
  920.     With lblDay(i)
  921.       If .Caption = CStr(HoyDay) And .BackColor <> vbRed Then If .BackColor <> Col Then .BackColor = Col
  922.     End With
  923.   Next i
  924. End Sub
  925. Private Sub LoadClock()
  926.   Dim i As Byte
  927.   Dim Mark As Boolean
  928.   Dim Rad As Long, Center As Long
  929.   Dim Ang As Double
  930.   Center = picClock.Height / 2
  931.   Rad = Center - 100
  932.   For i = 0 To 2
  933.     Clock(i).X1 = Center
  934.     Clock(i).Y1 = Center
  935.   Next i
  936.   For i = 1 To 60
  937.     Ang = i * 6 * Pi / 180
  938.     Mark = i / 5 = Int(i / 5)
  939.     picClock.DrawWidth = IIf(Mark, 2, 1)
  940.     picClock.PSet (Center + Sin(Ang) * Rad, Center + Cos(Ang) * Rad), IIf(Mark, vbRed, vbBlack)
  941.   Next i
  942.   tmrClock_Timer
  943. End Sub
  944. Private Sub Form_QueryUnload(Cancel As Integer, UnloadMode As Integer)
  945.   SetView False
  946.   Cancel = 1
  947. End Sub
  948. Private Sub lblDay_MouseDown(Index As Integer, Button As Integer, Shift As Integer, X As Single, Y As Single)
  949.   With lblDay(Index)
  950.     If Len(.Caption) Then
  951.       lstAppt.Clear
  952.       DiaSel = Val(.Caption)
  953.       DecolorCalendar
  954.       .BackColor = vbRed
  955.       MarkToday
  956.       LoadAppt
  957.     End If
  958.   End With
  959. End Sub
  960. Sub LoadAppt()
  961.   Dim Resp() As Long
  962.   Dim i As Long
  963.   txtAppt.Text = ""
  964.   lblAlarm.Caption = ""
  965.   cmdProperties.Enabled = False
  966.   cmdMove(0).Enabled = False
  967.   cmdMove(1).Enabled = False
  968.   cmdOp(0).Enabled = False
  969.   cmdOp(1).Enabled = False
  970.   TheresAppt Resp, DiaSel, cmbMonth.ListIndex + 1, Val(txtYear.Text), False, False
  971.   With lstAppt
  972.     .Clear
  973.     For i = 1 To UBound(Resp)
  974.       .AddItem Appt(Resp(i)).ApptName
  975.       .ItemData(.ListCount - 1) = Resp(i)
  976.     Next i
  977.   End With
  978.   lblCompleteDay.Caption = LoadCompleteDay(DiaSel, cmbMonth.ListIndex + 1, Val(txtYear.Text))
  979. End Sub
  980. Private Sub lstAppt_Click()
  981.   Dim Sel As Long
  982.   With lstAppt
  983.     Sel = .ListIndex
  984.     If Sel = -1 Then Exit Sub
  985.     cmdProperties.Enabled = True
  986.     cmdMove(0).Enabled = True
  987.     cmdMove(1).Enabled = True
  988.     cmdOp(0).Enabled = True
  989.     cmdOp(1).Enabled = True
  990.     With Appt(.ItemData(Sel))
  991.       txtAppt.Text = .Description
  992.       If .Alarm Then
  993.         lblAlarm.Caption = "Alarm set at " + FormatAlarm(.AlarmHr, .AlarmMin)
  994.       Else
  995.         lblAlarm.Caption = "Alarm not set"
  996.       End If
  997.     End With
  998.   End With
  999. End Sub
  1000. Private Sub lstAppt_DblClick()
  1001.   cmdProperties_Click
  1002. End Sub
  1003. Private Sub mnuAbout_Click()
  1004.   frmAbout.Show vbModal
  1005. End Sub
  1006. Private Sub mnuAdd_Click()
  1007.   Dim TmpStr As String
  1008.   TmpStr = InputBox("Add a new reminder")
  1009.   If Len(TmpStr) = 0 Then Exit Sub
  1010.   ReDim Preserve Appt(UBound(Appt) + 1)
  1011.   With lstAppt
  1012.     .AddItem TmpStr
  1013.     .ListIndex = .ListCount - 1
  1014.     .ItemData(.ListIndex) = UBound(Appt)
  1015.   End With
  1016.   Appt(UBound(Appt)).ApptName = TmpStr
  1017.   With Appt(UBound(Appt))
  1018.     .Mes = cmbMonth.ListIndex + 1
  1019.     .Dia = DiaSel
  1020.     .A
  1021. o = Val(txtYear.Text)
  1022.   End With
  1023.   frmProperties.Show vbModal
  1024.   LoadAppt
  1025. End Sub
  1026. Private Sub mnuOptions_Click()
  1027.   mnuAdd.Enabled = DiaSel
  1028.   mnuRemove.Enabled = lstAppt.ListIndex + 1
  1029. End Sub
  1030. Private Sub mnuExit_Click()
  1031.   SaveAppt
  1032.   End
  1033. End Sub
  1034. Private Sub mnuRemove_Click()
  1035.   If MsgBox("Are you sure you want to remove the selected reminder?", vbQuestion + vbYesNo) = vbNo Then Exit Sub
  1036.   RemoveAppt lstAppt.ItemData(lstAppt.ListIndex)
  1037.   LoadAppt
  1038. End Sub
  1039. Private Sub mnuRemoveAll_Click()
  1040.   If MsgBox("Are you sure you want to remove all reminders?", vbQuestion + vbYesNo) = vbNo Then Exit Sub
  1041.   ReDim Appt(0)
  1042.   LoadAppt
  1043. End Sub
  1044. Private Sub mnuStandBy_Click()
  1045.   SetView False
  1046. End Sub
  1047. Private Function LimitAng(ByVal Ang As Double) As Double
  1048.   LimitAng = Ang - 90
  1049.   If LimitAng < 0 Then LimitAng = 360 + LimitAng
  1050. End Function
  1051. Private Sub tmrClock_Timer()
  1052.   Dim Ang As Double
  1053.   Dim PM As String
  1054.   Dim Center As Long, Rad As Long, Hr As Long, Min As Long, Sec As Long
  1055.   Dim Current As Date
  1056.   Static LastNow As Date
  1057.   Current = Now()
  1058.   If LastNow = Current Then Exit Sub
  1059.   LastNow = Current
  1060.   Hr = Hour(Current)
  1061.   Min = Minute(Current)
  1062.   Sec = Second(Current)
  1063.   Center = picClock.Height / 2
  1064.   Rad = Center - 250
  1065.   Ang = LimitAng(Sec * 6) * Pi / 180
  1066.   With Clock(0)
  1067.     .Y2 = Center + Sin(Ang) * Rad
  1068.     .X2 = Center + Cos(Ang) * Rad
  1069.   End With
  1070.   Ang = LimitAng(Min * 6 + Sec / 60) * Pi / 180
  1071.   With Clock(1)
  1072.     .Y2 = Center + Sin(Ang) * Rad
  1073.     .X2 = Center + Cos(Ang) * Rad
  1074.   End With
  1075.   Ang = LimitAng((Hr Mod 12 + Min / 60) * 30) * Pi / 180
  1076.   Rad = Rad - 150
  1077.   With Clock(2)
  1078.     .Y2 = Center + Sin(Ang) * Rad
  1079.     .X2 = Center + Cos(Ang) * Rad
  1080.   End With
  1081.   If Hr > 11 Then
  1082.     PM = "PM"
  1083.   Else
  1084.     PM = "AM"
  1085.   End If
  1086.   If lblPm.Caption <> PM Then lblPm.Caption = PM
  1087.   MarkToday
  1088. End Sub
  1089. Private Sub txtYear_KeyPress(KeyAscii As Integer)
  1090.   LockDown = True
  1091.   Select Case KeyAscii
  1092.     Case vbKeyBack
  1093.     Case 13
  1094.       YearProcess
  1095.       GoTo NoBeep
  1096.     Case Is < vbKey0
  1097.       GoTo Error
  1098.     Case Is > vbKey9
  1099.       GoTo Error
  1100.   End Select
  1101.   Exit Sub
  1102. Error:
  1103.   Beep
  1104. NoBeep:
  1105.   KeyAscii = 0
  1106. End Sub
  1107. Private Sub txtYear_LostFocus()
  1108.   YearProcess
  1109. End Sub
  1110. Private Sub YearProcess()
  1111.   Dim Temp As Long
  1112.   LockDown = False
  1113.   Temp = Abs(Val(txtYear.Text))
  1114.   If Temp = 0 Then Temp = 1
  1115.   txtYear.Text = Temp
  1116.   LoadCalendar Temp, cmbMonth.ListIndex + 1, 1
  1117.   LoadAppt
  1118. End Sub
  1119. Sub SetView(ByVal Active As Boolean)
  1120.   tmrClock.Enabled = Active
  1121.   If Active Then
  1122.     RemoveFromTray
  1123.     Me.Show
  1124.   Else
  1125.     AddToTray
  1126.     Me.Hide
  1127.   End If
  1128. End Sub
  1129.