Professional Documents
Culture Documents
Chapter 1
Introduction
system that enables the facilitator to just operate their electrical maintenance that
lessen the hour of work by turning it on/off manually of the system. It is a must
that the University or other organization had this kind of wiring control system for
used by homes, facilities and also the Universities all over the world. Controlling
industrial workplace. It will reduce human errors and processing time, thus it can
boost productivityand will ultimately save a lot of time. Therefore, it has become
more necessary for common man to automate their homes or buildings to control
circuiting then led it into a massive fire. Moreover, safety of buildings from
2
dangers like short circuiting can also be addressed using the Appliance Wiring
Control System. Having an appliance wiring control system is much more helpful
than just having a breaker to shut all electric currents flowing all at once. In the
long run Appliance Wiring Control System will much more help in saving time,
saving money, Facility Maintenance and Security and also in making lives easy.
The System can also help the campus to prevent an accident that can
study development and evaluation of Appliance Wiring Control System for the
campus. The researchers believe that the study will of big help for the safety of
the faculty, staffs, students, facility maintenance staffs as well as the building
itself.
Technology has advanced so much in the last decade or two that it has
made life more efficient and comfortable. The comfort of being able to take
control of devices from one particular location has become imperative as it saves
breakthrough in technology over the years, the lives of people have become
busier than before. With the adoption of this system, we can gain control over
The application of this system comes in handy when people who forget to
offices. They can now do so without their presence by the transmission of simple
commands from the computer. This appliance control system does assistance to
the facilitators to monitor a real time update of the running appliance, without
even looking at the appliance directly by the help of the computer. It also helps in
the on and off of the appliances which may help for the facilitators to shut it in a
transactions.
people’s life easier, efficient and comfortable. The comfort of being able to take
control of devices from one particular location in which it saves a lot of time and
effort in which connects to the proposed system that the researchers will do.
It shows that control system has a lot of benefits that will help people to
make things easier in which in line with the system of the researchers, people
can save energy, time and efforts to do such thing regarding on the appliance
by a cell phone or a by palm top or by a PC. They are connected either through
from remote devices that are manipulated by user. The system in turn dispatch
responsible for keeping track of the states of the devices. If something goes
wrong, it will notify the user by sending messages back to the remote devices as
update of the running appliance, without even looking at the appliance directly by
the help of the computer. It also helps in the on and off of the appliances which
may help for the facilitators to shut it in a specific time whether the facilitator is in
hardware and software. Arduino boards are able to read inputs - light on a
activating a motor, turning on an LED, publishing something online. You can tell
The hardware Arduino uses to control the ON and OFF of the devices that
operate the Voltage Command to Pins reads from the serial port and routes of
form of Ferroelectric RAM, NOR flash or OTP ROM is also often included on
chips.5
normally open (NO), there is an open contact when the relay is not energized.
When a relay contact is Normally Closed (NC), there is a closed contact when
distribution lines by opening and closing circuit breakers, and perform time delay
functions.
communication with the first generator to selectively control the first generator in
controls load bearing equipment that consumes the power provided via the utility
power line and from the first generator. A process of managing power usage of a
plant comprises receiving energy pulses; determining actual kWh being delivered
preset kWh amount to determine whether actual kWh is greater than the preset
kWh amount; and, if the actual kWh is greater than the preset kWh amount, then
reducing the amount of power consumed by load bearing equipment. Also, if the
7
actual kWh is greater than the preset kWh amount, then the process increases
Home information centre, home appliance control system based on the Android
and wireless switch, home information center to form a complete system, and the
encoding are the two major tasks for home information center. Android phone
the control function, android phone allows us anytime, anywhere to control any
system is divided into two parts: server application software and microcontroller
communicate between remote user and the Home Gateway, configuration stage
Arduino.” 9
Mapua Institute of Technology. Based on the authors (Babierra, Arnel L.; Basa,
8
Erwin T.; Bitiu, 4 Jr. Palermo D.; Cruz, Rommel G. ;Layug III, Joel R.; and
Regaldo, Dante C.A.), “through the use of this system, one can automatically
control the status of the appliances even if they are away from home. This project
is a pc-based controller which allows users to switch six home appliances using
text message commands with the program created using Visual Basic 4 and
This system is similar to the group’s project design due to the fact that it
helps someone to turn their appliances ON or OFF. However there are difference
between the said study which allows controlling appliances using text message
commands and the System that the researchers made which can control
Theoretical Framework
when one or more output variables of a system need to follow a certain reference
over time.
effect on the output of the system. Rapid advances in digital system technology
have radically altered the control design options. It has become routinely
practicable to design very complicated digital controllers and to carry out the
The principle applies on the design of the project, wherein the arduino Uno
board operates to control the switch on/off in terms of controlling the system. The
programs in the database perform its necessary operation in order to monitor and
process.
operating properly and which actions are required to maintain the system in safe
Conceptual Framework
The first box is the input consists of ideas from related literatures and
The second box is the process contains and printing. This also includes
The third box is the output that shows the outcome which turn on/off the
The arrows represent the interrelationship of the input, process and the
Related Encoding
Literatures
and Studies Testing of the
System,
Data of the
University Administering Developed and
Facilities of Evaluated
Questionnaire Appliance Wiring
Checklist Control System
Arduino
Software Evaluation,
Analysis and
Questionnaire Interpretation
Checklist of Data
Gathered
Feedback
Figure 1
System.
of;
2.1 Accuracy;
2.2 Applicability;
2.3 Workability
2.5 Reliability.
variables
the system.
Hypothesis
The study aimed to create a system where the students, faculty and staffs
can ensure their safety in using the Facilities of the University. Study is confined
Through a help of the Arduinouno board, the system and the data base that is
university can easily control (on/off) the working appliance or can monitor on
which room the appliance is working, when the room is not being used.
data gathering which consist of five (5) variables, the Accuracy, Applicability,
together with the appropriate statistical tools such as the Mean, Standard
The study was limited on setting the On / Off of an appliance and was
done in one room in the first floor of the URS Cainta Campus.
14
Students,Through this system they are ensured that they are in the safe
learning environment.
else who will pursue the same study and may give some information in the study
The Maintenance Staff, This will help them in monitor running appliances
Definition of Terms
computer, as distinguished from the data it contains or operates on, and the
software that provides instructions for the hardware to perform specific tasks. 12
instructions, often broken into two major categories: system software that
wires.
Notes
1
Joan M. Padilla, An Overview of IT’s (Information Technology) Impact on the
Philippine Legal System, 2001
2
Control System, Retrieved on Aug. 30, 2016 from
https://en.wikipedia.org/wiki/Control_system
3
Duk-Jin Kimet. al, Home Appliance Control SystemOctober 12, 2006
4
Arduino, Retrieved on Sept. 10, 2016 from
https://www.arduino.cc/en/Guide/Introduction
5
Micro-Controller, Retrieved on Sept. 10, 2016 from
https://en.wikipedia.org/wiki/Microcontroller
6
Relay, Retrieved on Sept. 10, 2016 from
http://www.galco.com/comp/prod/relay.htm
7
Edwin Martin Cooley, et.al Power Control Systems and Processes Publication
numberUS6157874 A December 2000
8
Sachin KishorKhadke, Home Appliances Control System Based On Android
Smartphone Pune, India
9
Rajeev Piyare and Seong Ro Lee, Smart Home-Control and Monitoring
System Using Smart PhoneDepartment of Information Electronics
Engineering, Mokpo National University
10
Catherine A. Abayariet. alDesign of Home Appliance Remote Monitoring
and Switching System Using SMSMapua Institute of Technology March
2008
11
S. SimrockControl theory DESY, Hamburg, Germany
12
Software Retrieved on August 31, 2016
http://www.openprojects.org/software-definition.htm
13
Hardware Retrieved on August 31, 2016
http://www.openprojects.org/hardware-definition.htm
17
Chapter 2
RESEARCH METHODOLOGY
the study, subject of the study, source of data, research procedure, project
Research Design
does not answer questions about e.g.: how, when, why the characteristics
may help to uncover new facts and meaning. The purpose of descriptive
naturally occurs. This involves the collection of data that will provide an account
helpful for the development of a study. It is a research to know more about the
subject of the study which is the Staffs of University of Rizal System Cainta
18
Campus and also the method they use to have those important gathered data
The study includes the survey and the fact finding inquiries of different
kinds of variables .There are some valid concerns about the statistical validity, as
The Researchers developed their own system that involves the designing
and physical appearance of the said study. The method that the researchers
focused is more on the impact of the product on the learner or the organization.
Sampling Technique
Usually, the sample being investigated is quite small, especially when compared
convenience sampling.4
environmental stewardship”.
Today URS Cainta has become a complete college with Technology as its
continuously seeks to keep pace with other schools to meet the difficult and
presence in the Province of Rizal, URS Cainta located to a better site that will
20
Enable them to more efficiently meet the services needs and requirements of the
community.
Figure 2
Figure 3
the electronic appliances. It also aimed to create a system where the students,
faculty and staffs can ensure their safety in using the facilities of the campus.
Through this system, the staff can monitor on whom room does the
appliance accidentally forgot to turn off; it can stop consuming electricity and
expert, (14) Electrical expert and (3) Administrator. They were selected as the
output.
Sources of Data
data gathering tool in the evaluation of the developed Appliance Wiring Control
System.
Reliability
The researchers also used the internet and other unpublished study as the
secondary sources of the data that can also help the study to be more accurate.
Table 1
Research Procedure
titles and the panel approved the title "Development and Evaluation of the
their starting point. The researchers also gathered information from the internet,
study.
The researchers then began to develop their chapters 1 and 2 along with
the series of consultations with their adviser and the critic reader for the
improvement of the system and the manuscript. The researchers also sought
advices from the panel members. After the development of chapters 1 and 2 and
their flow chart/system, they prepared and successfully defended their study on
Project Design
The project design deals with the system flowchart which is defined as a
Flowchart
Start
A
HOME
A.Register
B.Log In
N
Y
N
Y
If = B A
Y B
Y
Input User and Password
Log In
N
Are the user is Valid? Error Messaged
Y
B
Y C
Y
MAIN
MENU
A. Output
Switch
B. Log out
2
25
Y D
Y
If = A OUTLET SWITCH
I. ON
II. OFF
Y
N If = I Y SWITCH ON
Y INDICATOR GREEN D
N Y
Y If = II Y SWITCH OFF
INDICATOR RED D
N
Y
C
Y
Y
If = B END
Logout
N
Y
C
26
Algorithm
1. Start
3. Log In
4. Main Menu
5. Profile
6. Switch Monitoring
7. Switching Schedule
7. Log Out
8. End
System - Cainta Campus is Dual-core processor, 2GB RAM, 512MB of video card, 80GB
hard disk, monitor (at least 1366 x 768 resolutions) mouse, keyboard and Arduino Uno board.
The software requirements are Net framework 4.0, Arduino Software, at least
Statistical Treatment
NOTES
1
Descriptive Research Design, Retrieved on Aug. 30, 2016 from
http://www.health.herts.ac.uk/immunology/Web%20programme%20-
%20Researchhealthprofessionals/descriptive_research.htm
2
Developmental Method, Retrieved on Aug. 30, 2016 from
http://en.wikipedia.org/wiki/develop ental-method
3
Purposive sampling, Retrieved on Aug. 30, 2016 from
http://dissertation.laerd.com/purposive-sampling.php
4
Convenience sampling, Retrieved on Aug. 30, 2016 from
http://dissertation.laerd.com/convenience-sampling.php
29
Chapter 3
algorithm, program listing, program output, user’s manual and the level of
In the development of the system, the researchers used VB 6.0 for the
designing as well coding of the system, C++ for the Arduino coding Microsoft
Access for the database as software and. To know the level of acceptability of
the program the researchers used descriptive and developmental method for
study.
To run the developed Appliance Wiring Control System, Visual Basic 6.0
Program Flowchart
START
LOG IN
N
VALID? ERROR MESSAGE
A
B
Y
MAIN MENU
A. ON/OFF SWITCH
B. SWITCH SCHEDULING
C. ON/OFF LOG
D. ADMIN PANEL
E. SUB MENU
2
31
C
Y
IF = A ON/OFF SWITCH
I. FIRST FLOOR
II. SECOND FLOOR
III. THIRD FLOOR
IV. FOURTH FLOOR
N FIRST FLOOR
D
Y I. 101
II. 102
IF = I III. 103
IV. 104
V. 105
VI. 1F CR
VII. 1F HALLWAY
N VIII. CLINIC
SECOND FLOOR
E
Y I. 201
II. 202
III. 203
IF = II IV. 204
V. 205
VI. 2F CR
VII. 2F HALLWAY
VIII. GUIDANCE OFFICE
N IX. MULTIPURPOSE ROOM
3
21
8
32
THIRD FLOOR
F
Y
I. 301
II. 302
IF = III III. 303
IV. 304
V. 305
VI. 3F CR
N
VII. 3F HALLWAY
VIII. RESEARCH OFFICE
13
FOURTH FLOOR
G
Y
I. 401
II. 402
IF = IV III. 403
IV. 404
V. 405
VI. 4F CR
N
VII. 4F HALLWAY
VIII. CHRONICLER
17
B
33
Y
IF = I 101
A. ON
B. OFF
N
Y
IF = A SWITCH ON
INDICATOR = GREEN D
N
Y
IF = B SWITCH OFF
INDICATOR = RED D
N
Y
IF = II 102
A. ON
B. OFF
N
Y
IF = A SWITCH ON
INDICATOR = GREEN D
N
Y
IF = B SWITCH OFF
INDICATOR = RED D
5 N
D
34
Y
IF = III 103
A. ON
B. OFF
N
Y
IF = A SWITCH ON
INDICATOR = GREEN D
N
Y
IF = B SWITCH OFF
INDICATOR = RED D
N
Y
IF = IV 104
A. ON
B. OFF
N
Y
IF = A SWITCH ON
INDICATOR = GREEN D
N
Y
IF = B SWITCH OFF
INDICATOR = RED D
6 N
D
35
Y
IF = V 105
A. ON
B. OFF
N
Y
IF = A SWITCH ON
INDICATOR = GREEN D
N
Y
IF = B SWITCH OFF
INDICATOR = RED D
N
Y
IF = VI 1F CR
A. ON
B. OFF
N
Y
IF = A SWITCH ON
INDICATOR = GREEN D
N
Y
IF = B SWITCH OFF
INDICATOR = RED D
7 N
D
36
Y
IF = VII 1F HALLWAY
A. ON
B. OFF
N
Y
IF = A SWITCH ON
INDICATOR = GREEN D
N
Y
IF = B SWITCH OFF
INDICATOR = RED D
N
Y
IF = VIII CLINIC
A. ON
B. OFF
N
Y
IF = A SWITCH ON
INDICATOR = GREEN D
N
Y
IF = B SWITCH OFF
INDICATOR = RED D
C N
D
37
Y
IF = I 201
A. ON
B. OFF
N
Y
IF = A SWITCH ON
INDICATOR = GREEN E
N
Y
IF = B SWITCH OFF
INDICATOR = RED E
N
Y
IF = II 202
A. ON
B. OFF
N
Y
IF = A SWITCH ON
INDICATOR = GREEN E
N
Y
IF = B SWITCH OFF
INDICATOR = RED E
9 N
E
38
Y
IF = III 203
A. ON
B. OFF
N
Y
IF = A SWITCH ON
INDICATOR = GREEN E
N
Y
IF = B SWITCH OFF
INDICATOR = RED E
N
Y
IF = IV 204
A. ON
B. OFF
N
Y
IF = A SWITCH ON
INDICATOR = GREEN E
N
Y
IF = B SWITCH OFF
INDICATOR = RED E
10 N
E
39
10
Y
IF = V 205
A. ON
B. OFF
N
Y
IF = A SWITCH ON
INDICATOR = GREEN E
N
Y
IF = B SWITCH OFF
INDICATOR = RED E
N
Y
IF = VI 2F CR
A. ON
B. OFF
N
Y
IF = A SWITCH ON
INDICATOR = GREEN E
N
Y
IF = B SWITCH OFF
INDICATOR = RED E
11 N
E
40
11
Y
IF = VII 2F HALLWAY
A. ON
B. OFF
N
Y
IF = A SWITCH ON
INDICATOR = GREEN E
N
Y
IF = B SWITCH OFF
INDICATOR = RED E
N
Y
GUIDANCE OFFICE
IF = VIII
A. ON
B. OFF
N
Y
IF = A SWITCH ON
INDICATOR = GREEN E
N
Y
IF = B SWITCH OFF
INDICATOR = RED E
12 N
E
41
12
Y
MULTIPURPOSE ROOM
IF = IX
A. ON
B. OFF
N
Y
IF = A SWITCH ON
INDICATOR = GREEN E
N
Y
IF = B SWITCH OFF
INDICATOR = RED E
N
E
C
42
13
Y
IF = I 301
A. ON
B. OFF
N
Y
IF = A SWITCH ON
INDICATOR = GREEN F
N
Y
IF = B SWITCH OFF
INDICATOR = RED F
N
Y
IF = II 302
A. ON
B. OFF
N
Y
IF = A SWITCH ON
INDICATOR = GREEN F
N
Y
IF = B SWITCH OFF
INDICATOR = RED F
14 N
F
43
14
Y
IF = III 303
A. ON
B. OFF
N
Y
IF = A SWITCH ON
INDICATOR = GREEN F
N
Y
IF = B SWITCH OFF
INDICATOR = RED F
N
Y
IF = IV 304
A. ON
B. OFF
N
Y
IF = A SWITCH ON
INDICATOR = GREEN F
N
Y
IF = B SWITCH OFF
INDICATOR = RED F
15 N
F
44
15
Y
IF = V 305
A. ON
B. OFF
N
Y
IF = A SWITCH ON
INDICATOR = GREEN F
N
Y
IF = B SWITCH OFF
INDICATOR = RED F
N
Y
IF = VI 3F CR
A. ON
B. OFF
N
Y
IF = A SWITCH ON
INDICATOR = GREEN F
N
Y
IF = B SWITCH OFF
INDICATOR = RED F
16 N
F
45
16
Y
3F HALLWAY
IF = VII
A. ON
B. OFF
N
Y
IF = A SWITCH ON
INDICATOR = GREEN F
N
Y
IF = B SWITCH OFF
INDICATOR = RED F
N
Y
IF = VIII RESEARCH OFFICE
A. ON
B. OFF
N
Y
IF = A SWITCH ON
INDICATOR = GREEN F
N
Y
IF = B SWITCH OFF
INDICATOR = RED F
C N
F
46
17
Y
IF = I 401
A. ON
B. OFF
N
Y
IF = A SWITCH ON
INDICATOR = GREEN G
N
Y
IF = B SWITCH OFF
INDICATOR = RED G
N
Y
IF = II 402
A. ON
B. OFF
N
Y
IF = A SWITCH ON
INDICATOR = GREEN G
N
Y
IF = B SWITCH OFF
INDICATOR = RED G
18 N
G
47
18
Y
IF = III 403
A. ON
B. OFF
N
Y
IF = A SWITCH ON
INDICATOR = GREEN G
N
Y
IF = B SWITCH OFF
INDICATOR = RED G
N
Y
IF = IV 404
A. ON
B. OFF
N
Y
IF = A SWITCH ON
INDICATOR = GREEN G
N
Y
IF = B SWITCH OFF
INDICATOR = RED G
19 N
G
48
19
Y
IF = V 405
A. ON
B. OFF
N
Y
IF = A SWITCH ON
INDICATOR = GREEN G
N
Y
IF = B SWITCH OFF
INDICATOR = RED G
N
Y
IF = VI 4F CR
A. ON
B. OFF
N
Y
IF = A SWITCH ON
INDICATOR = GREEN G
N
Y
IF = B SWITCH OFF
INDICATOR = RED G
20 N
G
49
20
Y
4F HALLWAY
IF = VII
A. ON
B. OFF
N
Y
IF = A SWITCH ON
INDICATOR = GREEN G
N
Y
IF = B SWITCH OFF
INDICATOR = RED G
N
Y
IF = VIII CHRONICLER
A. ON
B. OFF
N
Y
IF = A SWITCH ON
INDICATOR = GREEN G
N
Y
IF = B SWITCH OFF
INDICATOR = RED G
C N
G
50
21
H
Y
SWITCH SCHEDULING
IF = B I. FIRST FLOOR
II. SECOND FLOOR
III. THIRD FLOOR
IV. FOURTH FLOOR
IF = I A. SETUP
B. EDIT SETUP
IF = A
SETUP SAVE I
N
Y
IF = B
EDIT SAVE I
25 22 H
51
22
IF = II A. SETUP
B. EDIT SETUP
IF = A
SETUP
SAVE J
N
IF = B
EDIT
SAVE J
N
23 H
52
23
Y
K
SETUP THIRD FLOOR SCHEDULING
IF = III A. SETUP
B. EDIT SETUP
IF = A
SETUP
SAVE K
N
IF = B
EDIT
SAVE K
N
24 H
53
24
Y
L
SETUP FOURTH FLOOR SCHEDULING
IF = IV A. SETUP
B. EDIT SETUP
IF = A
SETUP
SAVE L
IF = B
EDIT
SAVE L
B H
54
25
IF = C ON / OFF LOGS
B
M
ADMIN PANEL
Y
IF = D I. USERS ACCOUNT
II. DELETE ALL ON/OFF LOGS
III. SETUP OUTPUTS DELAY
IV. SETUP DEVICE CONNECTION
V. FACTORY DATA RESET
30 26
55
26
USERS ACCOUNTS
IF = I
A. ADD ACCOUNT
B. EDIT ACCOUNT
C. DELETE ACCOUNT
IF = A
ADD ACCOUNT N
SAVE
Y
IF = B
EDIT ACCOUNT N
SAVE
N
Y
IF = C
DELETE N
27 M
56
27
O
Y
DELETE LOGS?
IF = II
A. YES
B. NO
N
Y
IF = A
DELETE O
Y
IF = B
O
28 M
57
28
Y P
SETUP OUTPUTS DELAY
IF = III
A. ACTIVATE
B. DEACTIVATE
IF = A SETUP ACTIVATE
P
IF = B DEACTIVATE P
29 M
58
29
Y
SETUP DEVICE CONNECTION
IF = IV
SAVE M
Q
Y
FACTORY DATA RESET
IF = V
A. OK
B. CANCEL
N
Y
IF = A CONFIRM RESETING
Q
N Y
IF = B
M
N
B Q
59
30
R
Y SUB MENU
I. POWER RESTORE
IF = E II. SHOW NOTIFICATION BAR
III. ABOUT AWCS
IV. LOGOUT
Y RESTORE POWER?
IF = I A. YES
B. NO
N
Y
IF = A RESTORING POWER
B
N
Y
IF = B
R
N
B
Y
IF = II SHOW NOTIFICATION BAR
N
Y
IF = III ABOUT AWCS
B
N
Y
IF = IV
END
N
B B
60
Program Algorithm
1. Start
2. Input Username and Password
3. Login
3.1 Login Failed
3.2 Back to Login Form
4. Main Menu
4.1 On/Off Switch
4.1.1 First Floor
4.1.1.1 Room 101
4.1.1.1.1 Output 1 Switch
4.1.1.1.2 Output 2 Switch
4.1.1.1.3 Output 3 Switch
4.1.1.1.4 Output 4 Switch
4.1.1.1.5 Edit Output Label
Program Listing
Timer2.Enabled = False
If AccountType.Text = "STANDARD" Then
With MainMenu
.Image4.Visible = False
.AdminFRAME.Visible = False
.Picture = LoadPicture(App.Path & "/Animations/Backgrounds/MainMenu/1u.jpg")
.DefaultBTN.Value = True
End With
If AccountType.Text = "ADMINISTRATOR" Then
With MainMenu
.Image4.Visible = True
.AdminFRAME.Visible = True
.Picture = LoadPicture(App.Path & "/Animations/Backgrounds/MainMenu/1.jpg")
.MBTN4.Visible = True
.DefaultBTN.Value = True
End With
End If
End If
MainMenu.Show
NotificationForm.Show
Me.Hide
Text1.Text = ""
Text2.Text = ""
End If
End If
End Sub
Option Explicit
FactoryData.Show
End Sub
.Columns(3).Width = "100"
.Columns(4).Width = "100"
.Columns(5).Width = "170"
.Font = "Arial Rounded MT Bold"
.Font.Size = "10"
.HeadLines = "2"
.HeadFont = "Bell MT"
.HeadFont.Size = "11"
.HeadFont.Bold = True
.MarqueeStyle = dbgHighlightRowRaiseCell
End With
End Sub
Call setrecord(Me.DBLogs, "select * from SwitchLOGS where DATE like'" & "12" & "%"
& "'")
Else
Call setrecord(Me.DBLogs, "select * from SwitchLOGS where DATE like'" &
Me.DateFilter.Text & "%" & "'")
End If
With DataGrid1
.Columns(0).Width = "200"
.Columns(1).Width = "200"
.Columns(2).Width = "60"
.Columns(3).Width = "100"
.Columns(4).Width = "100"
.Columns(5).Width = "170"
.Font = "Arial Rounded MT Bold"
.Font.Size = "10"
.HeadLines = "2"
.HeadFont = "Bell MT"
.HeadFont.Size = "11"
.HeadFont.Bold = True
.MarqueeStyle = dbgHighlightRowRaiseCell
End With
End Sub
Call setrecord(Me.DBLogs, "select * from SwitchLOGS where DATE like'" & "8" & "%" &
"'")
ElseIf DateFilter.Text = "SEPTEMBER (9)" Then
Call setrecord(Me.DBLogs, "select * from SwitchLOGS where DATE like'" & "9" & "%" &
"'")
ElseIf DateFilter.Text = "OCTOBER (10)" Then
Call setrecord(Me.DBLogs, "select * from SwitchLOGS where DATE like'" & "10" & "%"
& "'")
ElseIf DateFilter.Text = "NOVEMBER (11)" Then
Call setrecord(Me.DBLogs, "select * from SwitchLOGS where DATE like'" & "11" & "%"
& "'")
ElseIf DateFilter.Text = "DECEMBER (12)" Then
Call setrecord(Me.DBLogs, "select * from SwitchLOGS where DATE like'" & "12" & "%"
& "'")
Else
Call setrecord(Me.DBLogs, "select * from SwitchLOGS where DATE like'" &
Me.DateFilter.Text & "%" & "'")
End If
With DataGrid1
.Columns(0).Width = "200"
.Columns(1).Width = "200"
.Columns(2).Width = "60"
.Columns(3).Width = "100"
.Columns(4).Width = "100"
.Columns(5).Width = "170"
.Font = "Arial Rounded MT Bold"
.Font.Size = "10"
.HeadLines = "2"
.HeadFont = "Bell MT"
.HeadFont.Size = "11"
.HeadFont.Bold = True
.MarqueeStyle = dbgHighlightRowRaiseCell
End With
End Sub
Call setrecord(Me.DBLogs, "select * from SwitchLOGS where DATE like'" & "4" & "%" &
"'")
ElseIf DateFilter.Text = "MAY (5)" Then
Call setrecord(Me.DBLogs, "select * from SwitchLOGS where DATE like'" & "5" & "%" &
"'")
ElseIf DateFilter.Text = "JUNE (6)" Then
Call setrecord(Me.DBLogs, "select * from SwitchLOGS where DATE like'" & "6" & "%" &
"'")
ElseIf DateFilter.Text = "JULY (7)" Then
Call setrecord(Me.DBLogs, "select * from SwitchLOGS where DATE like'" & "7" & "%" &
"'")
ElseIf DateFilter.Text = "AUGUST (8)" Then
Call setrecord(Me.DBLogs, "select * from SwitchLOGS where DATE like'" & "8" & "%" &
"'")
ElseIf DateFilter.Text = "SEPTEMBER (9)" Then
Call setrecord(Me.DBLogs, "select * from SwitchLOGS where DATE like'" & "9" & "%" &
"'")
ElseIf DateFilter.Text = "OCTOBER (10)" Then
Call setrecord(Me.DBLogs, "select * from SwitchLOGS where DATE like'" & "10" & "%"
& "'")
ElseIf DateFilter.Text = "NOVEMBER (11)" Then
Call setrecord(Me.DBLogs, "select * from SwitchLOGS where DATE like'" & "11" & "%"
& "'")
ElseIf DateFilter.Text = "DECEMBER (12)" Then
Call setrecord(Me.DBLogs, "select * from SwitchLOGS where DATE like'" & "12" & "%"
& "'")
Else
Call setrecord(Me.DBLogs, "select * from SwitchLOGS where DATE like'" &
Me.DateFilter.Text & "%" & "'")
End If
With DataGrid1
.Columns(0).Width = "200"
.Columns(1).Width = "200"
.Columns(2).Width = "60"
.Columns(3).Width = "100"
.Columns(4).Width = "100"
.Columns(5).Width = "170"
.Font = "Arial Rounded MT Bold"
.Font.Size = "10"
.HeadLines = "2"
.HeadFont = "Bell MT"
.HeadFont.Size = "11"
.HeadFont.Bold = True
.MarqueeStyle = dbgHighlightRowRaiseCell
End With
End Sub
DateFilter.Text = "(ALL)"
SwitchFilter.Text = "(ALL)"
MenuFrame.Visible = False
MainMenu.WindowState = vbNormal
SchedulingCommands.SchedTimer.Value = True
If Splash.AccountType.Text = "STANDARD" Then
MainMenu.Picture = LoadPicture(App.Path &
"/Animations/Backgrounds/MainMenu/1u.jpg")
SwitchFRAME.Visible = True
SchedulingFRAME.Visible = False
LogFRAME.Visible = False
AdminFRAME.Visible = False
Image4.Visible = False
End If
If Splash.AccountType.Text = "ADMINISTRATOR" Then
MainMenu.Picture = LoadPicture(App.Path &
"/Animations/Backgrounds/MainMenu/1.jpg")
SwitchFRAME.Visible = True
SchedulingFRAME.Visible = False
LogFRAME.Visible = False
AdminFRAME.Visible = False
Image4.Visible = True
End If
End Sub
.Columns(3).Width = "80"
.Columns(4).Width = "60"
.Columns(5).Width = "100"
.Font = "Arial Rounded MT Bold"
.Font.Size = "8"
.HeadLines = "2"
.HeadFont = "Bell MT"
.HeadFont.Size = "11"
.HeadFont.Bold = True
.MarqueeStyle = dbgHighlightRowRaiseCell
End With
Call setrecord(Me.ActiveSchedule, "select * from ActiveSchedule where Status like'" &
"ACTIVATED" & "%" & "'")
With DataGrid2
.Columns(0).Width = "200"
.Columns(1).Width = "200"
.Font = "Arial Rounded MT Bold"
.Font.Size = "10"
.HeadLines = "2"
.HeadFont = "Bell MT"
.HeadFont.Size = "11"
.HeadFont.Bold = True
.MarqueeStyle = dbgHighlightRowRaiseCell
End With
End Sub
End Sub
End If
End Sub
Call setrecord(Me.DBLogs, "select * from SwitchLOGS where STATUS like'" & "" & "%"
& "'")
Else
Call setrecord(Me.DBLogs, "select * from SwitchLOGS where STATUS like'" &
Me.SwitchFilter.Text & "%" & "'")
End If
With DataGrid1
.Columns(0).Width = "200"
.Columns(1).Width = "200"
.Columns(2).Width = "60"
.Columns(3).Width = "100"
.Columns(4).Width = "100"
.Columns(5).Width = "170"
.Font = "Arial Rounded MT Bold"
.Font.Size = "10"
.HeadLines = "2"
.HeadFont = "Bell MT"
.HeadFont.Size = "11"
.HeadFont.Bold = True
.MarqueeStyle = dbgHighlightRowRaiseCell
End With
End Sub
buff1.Caption = Val(buff1.Caption) + 1
If buff1.Caption = "1" Then
Image1.Picture = LoadPicture(App.Path & "/Animations/ICONS/OnOff/Switch00.jpg")
ElseIf buff1.Caption = "2" Then
Image1.Picture = LoadPicture(App.Path & "/Animations/ICONS/OnOff/Switch01.jpg")
ElseIf buff1.Caption = "3" Then
Image1.Picture = LoadPicture(App.Path & "/Animations/ICONS/OnOff/Switch02.jpg")
ElseIf buff1.Caption = "4" Then
Image1.Picture = LoadPicture(App.Path & "/Animations/ICONS/OnOff/Switch03.jpg")
ElseIf buff1.Caption = "5" Then
Image1.Picture = LoadPicture(App.Path & "/Animations/ICONS/OnOff/Switch04.jpg")
ElseIf buff1.Caption = "6" Then
Image1.Picture = LoadPicture(App.Path & "/Animations/ICONS/OnOff/Switch05.jpg")
ElseIf buff1.Caption = "7" Then
Image1.Picture = LoadPicture(App.Path & "/Animations/ICONS/OnOff/Switch06.jpg")
ElseIf buff1.Caption = "8" Then
Image1.Picture = LoadPicture(App.Path & "/Animations/ICONS/OnOff/Switch07.jpg")
ElseIf buff1.Caption = "9" Then
Image1.Picture = LoadPicture(App.Path & "/Animations/ICONS/OnOff/Switch08.jpg")
ElseIf buff1.Caption = "10" Then
Image1.Picture = LoadPicture(App.Path & "/Animations/ICONS/OnOff/Switch09.jpg")
ElseIf buff1.Caption = "11" Then
Image1.Picture = LoadPicture(App.Path & "/Animations/ICONS/OnOff/Switch10.jpg")
ElseIf buff1.Caption = "12" Then
Image1.Picture = LoadPicture(App.Path & "/Animations/ICONS/OnOff/Switch11.jpg")
ElseIf buff1.Caption = "13" Then
Image1.Picture = LoadPicture(App.Path & "/Animations/ICONS/OnOff/Switch12.jpg")
ElseIf buff1.Caption = "14" Then
Image1.Picture = LoadPicture(App.Path & "/Animations/ICONS/OnOff/Switch13.jpg")
ElseIf buff1.Caption = "15" Then
Image1.Picture = LoadPicture(App.Path & "/Animations/ICONS/OnOff/Switch14.jpg")
ElseIf buff1.Caption = "16" Then
Image1.Picture = LoadPicture(App.Path & "/Animations/ICONS/OnOff/Switch15.jpg")
ElseIf buff1.Caption = "17" Then
Image1.Picture = LoadPicture(App.Path & "/Animations/ICONS/OnOff/Switch16.jpg")
ElseIf buff1.Caption = "18" Then
Image1.Picture = LoadPicture(App.Path & "/Animations/ICONS/OnOff/Switch17.jpg")
ElseIf buff1.Caption = "19" Then
Image1.Picture = LoadPicture(App.Path & "/Animations/ICONS/OnOff/Switch18.jpg")
ElseIf buff1.Caption = "20" Then
Image1.Picture = LoadPicture(App.Path & "/Animations/ICONS/OnOff/Switch19.jpg")
ElseIf buff1.Caption = "21" Then
Image1.Picture = LoadPicture(App.Path & "/Animations/ICONS/OnOff/Switch20.jpg")
ElseIf buff1.Caption = "22" Then
Image1.Picture = LoadPicture(App.Path & "/Animations/ICONS/OnOff/Switch21.jpg")
ElseIf buff1.Caption = "23" Then
Image1.Picture = LoadPicture(App.Path & "/Animations/ICONS/OnOff/Switch22.jpg")
ElseIf buff1.Caption = "24" Then
Image1.Picture = LoadPicture(App.Path & "/Animations/ICONS/OnOff/Switch23.jpg")
ElseIf buff1.Caption = "25" Then
Image1.Picture = LoadPicture(App.Path & "/Animations/ICONS/OnOff/Switch24.jpg")
100
buff2.Caption = Val(buff2.Caption) + 1
If buff2.Caption = "1" Then
Image2.Picture = LoadPicture(App.Path &
"/Animations/ICONS/Sched/Scheduling00.jpg")
ElseIf buff2.Caption = "2" Then
Image2.Picture = LoadPicture(App.Path &
"/Animations/ICONS/Sched/Scheduling01.jpg")
ElseIf buff2.Caption = "3" Then
Image2.Picture = LoadPicture(App.Path &
"/Animations/ICONS/Sched/Scheduling02.jpg")
ElseIf buff2.Caption = "4" Then
Image2.Picture = LoadPicture(App.Path &
"/Animations/ICONS/Sched/Scheduling03.jpg")
ElseIf buff2.Caption = "5" Then
Image2.Picture = LoadPicture(App.Path &
"/Animations/ICONS/Sched/Scheduling04.jpg")
ElseIf buff2.Caption = "6" Then
Image2.Picture = LoadPicture(App.Path &
"/Animations/ICONS/Sched/Scheduling05.jpg")
ElseIf buff2.Caption = "7" Then
Image2.Picture = LoadPicture(App.Path &
"/Animations/ICONS/Sched/Scheduling06.jpg")
ElseIf buff2.Caption = "8" Then
Image2.Picture = LoadPicture(App.Path &
"/Animations/ICONS/Sched/Scheduling07.jpg")
ElseIf buff2.Caption = "9" Then
Image2.Picture = LoadPicture(App.Path &
"/Animations/ICONS/Sched/Scheduling08.jpg")
ElseIf buff2.Caption = "10" Then
Image2.Picture = LoadPicture(App.Path &
"/Animations/ICONS/Sched/Scheduling09.jpg")
ElseIf buff2.Caption = "11" Then
Image2.Picture = LoadPicture(App.Path &
"/Animations/ICONS/Sched/Scheduling10.jpg")
ElseIf buff2.Caption = "12" Then
Image2.Picture = LoadPicture(App.Path &
"/Animations/ICONS/Sched/Scheduling11.jpg")
ElseIf buff2.Caption = "13" Then
Image2.Picture = LoadPicture(App.Path &
"/Animations/ICONS/Sched/Scheduling12.jpg")
ElseIf buff2.Caption = "14" Then
Image2.Picture = LoadPicture(App.Path &
"/Animations/ICONS/Sched/Scheduling13.jpg")
ElseIf buff2.Caption = "15" Then
Image2.Picture = LoadPicture(App.Path &
"/Animations/ICONS/Sched/Scheduling14.jpg")
ElseIf buff2.Caption = "16" Then
Image2.Picture = LoadPicture(App.Path &
"/Animations/ICONS/Sched/Scheduling15.jpg")
ElseIf buff2.Caption = "17" Then
102
buff4.Caption = Val(buff4.Caption) + 1
If buff4.Caption = "1" Then
Image4.Picture = LoadPicture(App.Path & "/Animations/ICONS/Admin/Admin00.jpg")
ElseIf buff4.Caption = "2" Then
Image4.Picture = LoadPicture(App.Path & "/Animations/ICONS/Admin/Admin01.jpg")
ElseIf buff4.Caption = "3" Then
Image4.Picture = LoadPicture(App.Path & "/Animations/ICONS/Admin/Admin02.jpg")
ElseIf buff4.Caption = "4" Then
Image4.Picture = LoadPicture(App.Path & "/Animations/ICONS/Admin/Admin03.jpg")
ElseIf buff4.Caption = "5" Then
Image4.Picture = LoadPicture(App.Path & "/Animations/ICONS/Admin/Admin04.jpg")
ElseIf buff4.Caption = "6" Then
Image4.Picture = LoadPicture(App.Path & "/Animations/ICONS/Admin/Admin05.jpg")
ElseIf buff4.Caption = "7" Then
Image4.Picture = LoadPicture(App.Path & "/Animations/ICONS/Admin/Admin06.jpg")
ElseIf buff4.Caption = "8" Then
Image4.Picture = LoadPicture(App.Path & "/Animations/ICONS/Admin/Admin07.jpg")
ElseIf buff4.Caption = "9" Then
Image4.Picture = LoadPicture(App.Path & "/Animations/ICONS/Admin/Admin08.jpg")
ElseIf buff4.Caption = "10" Then
Image4.Picture = LoadPicture(App.Path & "/Animations/ICONS/Admin/Admin09.jpg")
ElseIf buff4.Caption = "11" Then
Image4.Picture = LoadPicture(App.Path & "/Animations/ICONS/Admin/Admin10.jpg")
ElseIf buff4.Caption = "12" Then
Image4.Picture = LoadPicture(App.Path & "/Animations/ICONS/Admin/Admin11.jpg")
ElseIf buff4.Caption = "13" Then
Image4.Picture = LoadPicture(App.Path & "/Animations/ICONS/Admin/Admin12.jpg")
ElseIf buff4.Caption = "14" Then
Image4.Picture = LoadPicture(App.Path & "/Animations/ICONS/Admin/Admin13.jpg")
ElseIf buff4.Caption = "15" Then
Image4.Picture = LoadPicture(App.Path & "/Animations/ICONS/Admin/Admin14.jpg")
ElseIf buff4.Caption = "16" Then
Image4.Picture = LoadPicture(App.Path & "/Animations/ICONS/Admin/Admin15.jpg")
ElseIf buff4.Caption = "17" Then
Image4.Picture = LoadPicture(App.Path & "/Animations/ICONS/Admin/Admin16.jpg")
ElseIf buff4.Caption = "18" Then
Image4.Picture = LoadPicture(App.Path & "/Animations/ICONS/Admin/Admin17.jpg")
ElseIf buff4.Caption = "19" Then
Image4.Picture = LoadPicture(App.Path & "/Animations/ICONS/Admin/Admin18.jpg")
ElseIf buff4.Caption = "20" Then
Image4.Picture = LoadPicture(App.Path & "/Animations/ICONS/Admin/Admin19.jpg")
ElseIf buff4.Caption = "21" Then
Image4.Picture = LoadPicture(App.Path & "/Animations/ICONS/Admin/Admin20.jpg")
ElseIf buff4.Caption = "22" Then
Image4.Picture = LoadPicture(App.Path & "/Animations/ICONS/Admin/Admin21.jpg")
ElseIf buff4.Caption = "23" Then
Image4.Picture = LoadPicture(App.Path & "/Animations/ICONS/Admin/Admin22.jpg")
ElseIf buff4.Caption = "24" Then
Image4.Picture = LoadPicture(App.Path & "/Animations/ICONS/Admin/Admin23.jpg")
ElseIf buff4.Caption = "25" Then
Image4.Picture = LoadPicture(App.Path & "/Animations/ICONS/Admin/Admin24.jpg")
107
Server1F.L101O1.Text = Server1F.DB101.Recordset.Fields("O1LABEL")
Server1F.L101O2.Text = Server1F.DB101.Recordset.Fields("O2LABEL")
Server1F.L101O3.Text = Server1F.DB101.Recordset.Fields("O3LABEL")
Server1F.L101O4.Text = Server1F.DB101.Recordset.Fields("O4LABEL")
Server1F.S101.Text = Server1F.DB101.Recordset.Fields("STATUS")
Server1F.C101.Text = Server1F.DB101.Recordset.Fields("COMPORT")
Server1F.O1S101.Text = Server1F.DB101.Recordset.Fields("O1STATUS")
Server1F.O2S101.Text = Server1F.DB101.Recordset.Fields("O2STATUS")
Server1F.O3S101.Text = Server1F.DB101.Recordset.Fields("O3STATUS")
Server1F.O4S101.Text = Server1F.DB101.Recordset.Fields("O4STATUS")
Server1F.OD101O1.Text = Server1F.DB101.Recordset.Fields("O1OUTPUTDELAY")
Server1F.OD101O2.Text = Server1F.DB101.Recordset.Fields("O2OUTPUTDELAY")
Server1F.OD101O3.Text = Server1F.DB101.Recordset.Fields("O3OUTPUTDELAY")
Server1F.OD101O4.Text = Server1F.DB101.Recordset.Fields("O4OUTPUTDELAY")
ROOM101.ROOMLABEL.Caption = BTN101.Caption
ROOM101.O1BTN.Caption = Server1F.L101O1.Text
ROOM101.O2BTN.Caption = Server1F.L101O2.Text
ROOM101.O3BTN.Caption = Server1F.L101O3.Text
ROOM101.O4BTN.Caption = Server1F.L101O4.Text
ROOM101.O1BTNOFF.Caption = Server1F.L101O1.Text
ROOM101.O2BTNOFF.Caption = Server1F.L101O2.Text
ROOM101.O3BTNOFF.Caption = Server1F.L101O3.Text
ROOM101.O4BTNOFF.Caption = Server1F.L101O4.Text
ROOM101.S1.Caption = Server1F.L101O1.Text
ROOM101.S2.Caption = Server1F.L101O2.Text
ROOM101.S3.Caption = Server1F.L101O3.Text
ROOM101.S4.Caption = Server1F.L101O4.Text
ROOM101.O1ELabel.Text = Server1F.L101O1.Text
ROOM101.O2ELabel.Text = Server1F.L101O2.Text
ROOM101.O3ELabel.Text = Server1F.L101O3.Text
ROOM101.O4ELabel.Text = Server1F.L101O4.Text
ROOM101.O1Delay.Caption = Server1F.OD101O1.Text & " Minute/s"
ROOM101.O2Delay.Caption = Server1F.OD101O2.Text & " Minute/s"
ROOM101.O3Delay.Caption = Server1F.OD101O3.Text & " Minute/s"
ROOM101.O4Delay.Caption = Server1F.OD101O4.Text & " Minute/s"
If ROOM101.Arduino.PortOpen = True Then
ROOM101.Arduino.PortOpen = False
Else
ROOM101.Arduino.RThreshold = 3
ROOM101.Arduino.Settings = "9600,n,8,1"
ROOM101.Arduino.CommPort = Server1F.C101.Text
ROOM101.Arduino.PortOpen = True
ROOM101.Arduino.DTREnable = False
ROOM101.Show 1, S1Floor
End If
End Sub
Server1F.L102O2.Text = Server1F.DB102.Recordset.Fields("O2LABEL")
Server1F.L102O3.Text = Server1F.DB102.Recordset.Fields("O3LABEL")
Server1F.L102O4.Text = Server1F.DB102.Recordset.Fields("O4LABEL")
Server1F.S102.Text = Server1F.DB102.Recordset.Fields("STATUS")
Server1F.C102.Text = Server1F.DB102.Recordset.Fields("COMPORT")
Server1F.O1S102.Text = Server1F.DB102.Recordset.Fields("O1STATUS")
Server1F.O2S102.Text = Server1F.DB102.Recordset.Fields("O2STATUS")
Server1F.O3S102.Text = Server1F.DB102.Recordset.Fields("O3STATUS")
Server1F.O4S102.Text = Server1F.DB102.Recordset.Fields("O4STATUS")
Server1F.OD102O1.Text = Server1F.DB102.Recordset.Fields("O1OUTPUTDELAY")
Server1F.OD102O2.Text = Server1F.DB102.Recordset.Fields("O2OUTPUTDELAY")
Server1F.OD102O3.Text = Server1F.DB102.Recordset.Fields("O3OUTPUTDELAY")
Server1F.OD102O4.Text = Server1F.DB102.Recordset.Fields("O4OUTPUTDELAY")
ROOM102.ROOMLABEL.Caption = BTN102.Caption
ROOM102.O1BTN.Caption = Server1F.L102O1.Text
ROOM102.O2BTN.Caption = Server1F.L102O2.Text
ROOM102.O3BTN.Caption = Server1F.L102O3.Text
ROOM102.O4BTN.Caption = Server1F.L102O4.Text
ROOM102.O1BTNOFF.Caption = Server1F.L102O1.Text
ROOM102.O2BTNOFF.Caption = Server1F.L102O2.Text
ROOM102.O3BTNOFF.Caption = Server1F.L102O3.Text
ROOM102.O4BTNOFF.Caption = Server1F.L102O4.Text
ROOM102.S1.Caption = Server1F.L102O1.Text
ROOM102.S2.Caption = Server1F.L102O2.Text
ROOM102.S3.Caption = Server1F.L102O3.Text
ROOM102.S4.Caption = Server1F.L102O4.Text
ROOM102.O1ELabel.Text = Server1F.L102O1.Text
ROOM102.O2ELabel.Text = Server1F.L102O2.Text
ROOM102.O3ELabel.Text = Server1F.L102O3.Text
ROOM102.O4ELabel.Text = Server1F.L102O4.Text
ROOM102.O1Delay.Caption = Server1F.OD102O1.Text & " Minute/s"
ROOM102.O2Delay.Caption = Server1F.OD102O2.Text & " Minute/s"
ROOM102.O3Delay.Caption = Server1F.OD102O3.Text & " Minute/s"
ROOM102.O4Delay.Caption = Server1F.OD102O4.Text & " Minute/s"
If ROOM102.Arduino.PortOpen = True Then
ROOM102.Arduino.PortOpen = False
Else
ROOM102.Arduino.RThreshold = 3
ROOM102.Arduino.Settings = "9600,n,8,1"
ROOM102.Arduino.CommPort = Server1F.C102.Text
ROOM102.Arduino.PortOpen = True
ROOM102.Arduino.DTREnable = False
ROOM102.Show 1, S1Floor
End If
End Sub
Server1F.L103O3.Text = Server1F.DB103.Recordset.Fields("O3LABEL")
Server1F.L103O4.Text = Server1F.DB103.Recordset.Fields("O4LABEL")
Server1F.S103.Text = Server1F.DB103.Recordset.Fields("STATUS")
Server1F.C103.Text = Server1F.DB103.Recordset.Fields("COMPORT")
Server1F.O1S103.Text = Server1F.DB103.Recordset.Fields("O1STATUS")
Server1F.O2S103.Text = Server1F.DB103.Recordset.Fields("O2STATUS")
Server1F.O3S103.Text = Server1F.DB103.Recordset.Fields("O3STATUS")
Server1F.O4S103.Text = Server1F.DB103.Recordset.Fields("O4STATUS")
Server1F.OD103O1.Text = Server1F.DB103.Recordset.Fields("O1OUTPUTDELAY")
Server1F.OD103O2.Text = Server1F.DB103.Recordset.Fields("O2OUTPUTDELAY")
Server1F.OD103O3.Text = Server1F.DB103.Recordset.Fields("O3OUTPUTDELAY")
Server1F.OD103O4.Text = Server1F.DB103.Recordset.Fields("O4OUTPUTDELAY")
ROOM103.ROOMLABEL.Caption = BTN103.Caption
ROOM103.O1BTN.Caption = Server1F.L103O1.Text
ROOM103.O2BTN.Caption = Server1F.L103O2.Text
ROOM103.O3BTN.Caption = Server1F.L103O3.Text
ROOM103.O4BTN.Caption = Server1F.L103O4.Text
ROOM103.O1BTNOFF.Caption = Server1F.L103O1.Text
ROOM103.O2BTNOFF.Caption = Server1F.L103O2.Text
ROOM103.O3BTNOFF.Caption = Server1F.L103O3.Text
ROOM103.O4BTNOFF.Caption = Server1F.L103O4.Text
ROOM103.S1.Caption = Server1F.L103O1.Text
ROOM103.S2.Caption = Server1F.L103O2.Text
ROOM103.S3.Caption = Server1F.L103O3.Text
ROOM103.S4.Caption = Server1F.L103O4.Text
ROOM103.O1ELabel.Text = Server1F.L103O1.Text
ROOM103.O2ELabel.Text = Server1F.L103O2.Text
ROOM103.O3ELabel.Text = Server1F.L103O3.Text
ROOM103.O4ELabel.Text = Server1F.L103O4.Text
ROOM103.O1Delay.Caption = Server1F.OD103O1.Text & " Minute/s"
ROOM103.O2Delay.Caption = Server1F.OD103O2.Text & " Minute/s"
ROOM103.O3Delay.Caption = Server1F.OD103O3.Text & " Minute/s"
ROOM103.O4Delay.Caption = Server1F.OD103O4.Text & " Minute/s"
If ROOM103.Arduino.PortOpen = True Then
ROOM103.Arduino.PortOpen = False
Else
ROOM103.Arduino.RThreshold = 3
ROOM103.Arduino.Settings = "9600,n,8,1"
ROOM103.Arduino.CommPort = Server1F.C103.Text
ROOM103.Arduino.PortOpen = True
ROOM103.Arduino.DTREnable = False
ROOM103.Show 1, S1Floor
End If
End Sub
Server1F.L104O3.Text = Server1F.DB104.Recordset.Fields("O3LABEL")
Server1F.L104O4.Text = Server1F.DB104.Recordset.Fields("O4LABEL")
Server1F.S104.Text = Server1F.DB104.Recordset.Fields("STATUS")
Server1F.C104.Text = Server1F.DB104.Recordset.Fields("COMPORT")
Server1F.O1S104.Text = Server1F.DB104.Recordset.Fields("O1STATUS")
Server1F.O2S104.Text = Server1F.DB104.Recordset.Fields("O2STATUS")
Server1F.O3S104.Text = Server1F.DB104.Recordset.Fields("O3STATUS")
Server1F.O4S104.Text = Server1F.DB104.Recordset.Fields("O4STATUS")
Server1F.OD104O1.Text = Server1F.DB104.Recordset.Fields("O1OUTPUTDELAY")
Server1F.OD104O2.Text = Server1F.DB104.Recordset.Fields("O2OUTPUTDELAY")
Server1F.OD104O3.Text = Server1F.DB104.Recordset.Fields("O3OUTPUTDELAY")
Server1F.OD104O4.Text = Server1F.DB104.Recordset.Fields("O4OUTPUTDELAY")
ROOM104.ROOMLABEL.Caption = BTN104.Caption
ROOM104.O1BTN.Caption = Server1F.L104O1.Text
ROOM104.O2BTN.Caption = Server1F.L104O2.Text
ROOM104.O3BTN.Caption = Server1F.L104O3.Text
ROOM104.O4BTN.Caption = Server1F.L104O4.Text
ROOM104.O1BTNOFF.Caption = Server1F.L104O1.Text
ROOM104.O2BTNOFF.Caption = Server1F.L104O2.Text
ROOM104.O3BTNOFF.Caption = Server1F.L104O3.Text
ROOM104.O4BTNOFF.Caption = Server1F.L104O4.Text
ROOM104.S1.Caption = Server1F.L104O1.Text
ROOM104.S2.Caption = Server1F.L104O2.Text
ROOM104.S3.Caption = Server1F.L104O3.Text
ROOM104.S4.Caption = Server1F.L104O4.Text
ROOM104.O1ELabel.Text = Server1F.L104O1.Text
ROOM104.O2ELabel.Text = Server1F.L104O2.Text
ROOM104.O3ELabel.Text = Server1F.L104O3.Text
ROOM104.O4ELabel.Text = Server1F.L104O4.Text
ROOM104.O1Delay.Caption = Server1F.OD104O1.Text & " Minute/s"
ROOM104.O2Delay.Caption = Server1F.OD104O2.Text & " Minute/s"
ROOM104.O3Delay.Caption = Server1F.OD104O3.Text & " Minute/s"
ROOM104.O4Delay.Caption = Server1F.OD104O4.Text & " Minute/s"
If ROOM104.Arduino.PortOpen = True Then
ROOM104.Arduino.PortOpen = False
Else
ROOM104.Arduino.RThreshold = 3
ROOM104.Arduino.Settings = "9600,n,8,1"
ROOM104.Arduino.CommPort = Server1F.C104.Text
ROOM104.Arduino.PortOpen = True
ROOM104.Arduino.DTREnable = False
ROOM104.Show 1, S1Floor
End If
End Sub
Server1F.L105O4.Text = Server1F.DB105.Recordset.Fields("O4LABEL")
Server1F.S105.Text = Server1F.DB105.Recordset.Fields("STATUS")
Server1F.C105.Text = Server1F.DB105.Recordset.Fields("COMPORT")
Server1F.O1S105.Text = Server1F.DB105.Recordset.Fields("O1STATUS")
Server1F.O2S105.Text = Server1F.DB105.Recordset.Fields("O2STATUS")
Server1F.O3S105.Text = Server1F.DB105.Recordset.Fields("O3STATUS")
Server1F.O4S105.Text = Server1F.DB105.Recordset.Fields("O4STATUS")
Server1F.OD105O1.Text = Server1F.DB105.Recordset.Fields("O1OUTPUTDELAY")
Server1F.OD105O2.Text = Server1F.DB105.Recordset.Fields("O2OUTPUTDELAY")
Server1F.OD105O3.Text = Server1F.DB105.Recordset.Fields("O3OUTPUTDELAY")
Server1F.OD105O4.Text = Server1F.DB105.Recordset.Fields("O4OUTPUTDELAY")
ROOM105.ROOMLABEL.Caption = BTN105.Caption
ROOM105.O1BTN.Caption = Server1F.L105O1.Text
ROOM105.O2BTN.Caption = Server1F.L105O2.Text
ROOM105.O3BTN.Caption = Server1F.L105O3.Text
ROOM105.O4BTN.Caption = Server1F.L105O4.Text
ROOM105.O1BTNOFF.Caption = Server1F.L105O1.Text
ROOM105.O2BTNOFF.Caption = Server1F.L105O2.Text
ROOM105.O3BTNOFF.Caption = Server1F.L105O3.Text
ROOM105.O4BTNOFF.Caption = Server1F.L105O4.Text
ROOM105.S1.Caption = Server1F.L105O1.Text
ROOM105.S2.Caption = Server1F.L105O2.Text
ROOM105.S3.Caption = Server1F.L105O3.Text
ROOM105.S4.Caption = Server1F.L105O4.Text
ROOM105.O1ELabel.Text = Server1F.L105O1.Text
ROOM105.O2ELabel.Text = Server1F.L105O2.Text
ROOM105.O3ELabel.Text = Server1F.L105O3.Text
ROOM105.O4ELabel.Text = Server1F.L105O4.Text
ROOM105.O1Delay.Caption = Server1F.OD105O1.Text & " Minute/s"
ROOM105.O2Delay.Caption = Server1F.OD105O2.Text & " Minute/s"
ROOM105.O3Delay.Caption = Server1F.OD105O3.Text & " Minute/s"
ROOM105.O4Delay.Caption = Server1F.OD105O4.Text & " Minute/s"
If ROOM105.Arduino.PortOpen = True Then
ROOM105.Arduino.PortOpen = False
Else
ROOM105.Arduino.RThreshold = 3
ROOM105.Arduino.Settings = "9600,n,8,1"
ROOM105.Arduino.CommPort = Server1F.C105.Text
ROOM105.Arduino.PortOpen = True
ROOM105.Arduino.DTREnable = False
ROOM105.Show 1, S1Floor
End If
End Sub
Server1F.L1FCRO4.Text = Server1F.DB1FCR.Recordset.Fields("O4LABEL")
Server1F.S1FCR.Text = Server1F.DB1FCR.Recordset.Fields("STATUS")
Server1F.C1FCR.Text = Server1F.DB1FCR.Recordset.Fields("COMPORT")
Server1F.O1S1FCR.Text = Server1F.DB1FCR.Recordset.Fields("O1STATUS")
Server1F.O2S1FCR.Text = Server1F.DB1FCR.Recordset.Fields("O2STATUS")
Server1F.O3S1FCR.Text = Server1F.DB1FCR.Recordset.Fields("O3STATUS")
Server1F.O4S1FCR.Text = Server1F.DB1FCR.Recordset.Fields("O4STATUS")
Server1F.OD1FCRO1.Text =
Server1F.DB1FCR.Recordset.Fields("O1OUTPUTDELAY")
Server1F.OD1FCRO2.Text =
Server1F.DB1FCR.Recordset.Fields("O2OUTPUTDELAY")
Server1F.OD1FCRO3.Text =
Server1F.DB1FCR.Recordset.Fields("O3OUTPUTDELAY")
Server1F.OD1FCRO4.Text =
Server1F.DB1FCR.Recordset.Fields("O4OUTPUTDELAY")
ROOM1FCR.ROOMLABEL.Caption = BTN1FCR.Caption
ROOM1FCR.O1BTN.Caption = Server1F.L1FCRO1.Text
ROOM1FCR.O2BTN.Caption = Server1F.L1FcrO2.Text
ROOM1FCR.O3BTN.Caption = Server1F.L1FCRO3.Text
ROOM1FCR.O4BTN.Caption = Server1F.L1FCRO4.Text
ROOM1FCR.O1BTNOFF.Caption = Server1F.L1FCRO1.Text
ROOM1FCR.O2BTNOFF.Caption = Server1F.L1FcrO2.Text
ROOM1FCR.O3BTNOFF.Caption = Server1F.L1FCRO3.Text
ROOM1FCR.O4BTNOFF.Caption = Server1F.L1FCRO4.Text
ROOM1FCR.S1.Caption = Server1F.L1FCRO1.Text
ROOM1FCR.S2.Caption = Server1F.L1FcrO2.Text
ROOM1FCR.S3.Caption = Server1F.L1FCRO3.Text
ROOM1FCR.S4.Caption = Server1F.L1FCRO4.Text
ROOM1FCR.O1ELabel.Text = Server1F.L1FCRO1.Text
ROOM1FCR.O2ELabel.Text = Server1F.L1FcrO2.Text
ROOM1FCR.O3ELabel.Text = Server1F.L1FCRO3.Text
ROOM1FCR.O4ELabel.Text = Server1F.L1FCRO4.Text
ROOM1FCR.O1Delay.Caption = Server1F.OD1FCRO1.Text & " Minute/s"
ROOM1FCR.O2Delay.Caption = Server1F.OD1FCRO2.Text & " Minute/s"
ROOM1FCR.O3Delay.Caption = Server1F.OD1FCRO3.Text & " Minute/s"
ROOM1FCR.O4Delay.Caption = Server1F.OD1FCRO4.Text & " Minute/s"
If ROOM1FCR.Arduino.PortOpen = True Then
ROOM1FCR.Arduino.PortOpen = False
Else
ROOM1FCR.Arduino.RThreshold = 3
ROOM1FCR.Arduino.Settings = "9600,n,8,1"
ROOM1FCR.Arduino.CommPort = Server1F.C1FCR.Text
ROOM1FCR.Arduino.PortOpen = True
ROOM1FCR.Arduino.DTREnable = False
ROOM1FCR.Show 1, S1Floor
End If
End Sub
End If
End Sub
ROOMCLINIC.Arduino.CommPort = Server1F.CCLINIC.Text
ROOMCLINIC.Arduino.PortOpen = True
ROOMCLINIC.Arduino.DTREnable = False
ROOMCLINIC.Show 1, S1Floor
End If
End Sub
End If
If .SS1FCR.Text = "ACTIVATED" Then
S1Floor.BTN1FCR.BackColor = RGB(78, 0, 255)
S1Floor.BTN1FCR.BackOver = RGB(0, 126, 255)
End If
If .SS1FHW.Text = "ACTIVATED" Then
S1Floor.BTN1FHW.BackColor = RGB(78, 0, 255)
S1Floor.BTN1FHW.BackOver = RGB(0, 126, 255)
End If
If .SSCLINIC.Text = "ACTIVATED" Then
S1Floor.BTNCLINIC.BackColor = RGB(78, 0, 255)
S1Floor.BTNCLINIC.BackOver = RGB(0, 126, 255)
End If
If .S101.Text = "DEACTIVATED" Then
S1Floor.BTN101.BackColor = RGB(255, 102, 0)
S1Floor.BTN101.Enabled = False
End If
If .S102.Text = "DEACTIVATED" Then
S1Floor.BTN102.BackColor = RGB(255, 102, 0)
S1Floor.BTN102.Enabled = False
End If
If .S103.Text = "DEACTIVATED" Then
S1Floor.BTN103.BackColor = RGB(255, 102, 0)
S1Floor.BTN103.Enabled = False
End If
If .S104.Text = "DEACTIVATED" Then
S1Floor.BTN104.BackColor = RGB(255, 102, 0)
S1Floor.BTN104.Enabled = False
End If
If .S105.Text = "DEACTIVATED" Then
S1Floor.BTN105.BackColor = RGB(255, 102, 0)
S1Floor.BTN105.Enabled = False
End If
If .S1FCR.Text = "DEACTIVATED" Then
S1Floor.BTN1FCR.BackColor = RGB(255, 102, 0)
S1Floor.BTN1FCR.Enabled = False
End If
If .S1FHW.Text = "DEACTIVATED" Then
S1Floor.BTN1FHW.BackColor = RGB(255, 102, 0)
S1Floor.BTN1FHW.Enabled = False
End If
If .SCLINIC.Text = "DEACTIVATED" Then
S1Floor.BTNCLINIC.BackColor = RGB(255, 102, 0)
S1Floor.BTNCLINIC.Enabled = False
End If
If .S101.Text = "ACTIVATED" Then
S1Floor.BTN101.Enabled = True
End If
If .S102.Text = "ACTIVATED" Then
S1Floor.BTN102.Enabled = True
End If
118
Server1F.O2S101.Text = Server1F.DB101.Recordset.Fields("O2STATUS")
Server1F.O3S101.Text = Server1F.DB101.Recordset.Fields("O3STATUS")
Server1F.O4S101.Text = Server1F.DB101.Recordset.Fields("O4STATUS")
Server1F.OD101O1.Text = Server1F.DB101.Recordset.Fields("O1OUTPUTDELAY")
Server1F.OD101O2.Text = Server1F.DB101.Recordset.Fields("O2OUTPUTDELAY")
Server1F.OD101O3.Text = Server1F.DB101.Recordset.Fields("O3OUTPUTDELAY")
Server1F.OD101O4.Text = Server1F.DB101.Recordset.Fields("O4OUTPUTDELAY")
ROOM101.O1BTN.Caption = Server1F.L101O1.Text
ROOM101.O2BTN.Caption = Server1F.L101O2.Text
ROOM101.O3BTN.Caption = Server1F.L101O3.Text
ROOM101.O4BTN.Caption = Server1F.L101O4.Text
ROOM101.O1BTNOFF.Caption = Server1F.L101O1.Text
ROOM101.O2BTNOFF.Caption = Server1F.L101O2.Text
ROOM101.O3BTNOFF.Caption = Server1F.L101O3.Text
ROOM101.O4BTNOFF.Caption = Server1F.L101O4.Text
ROOM101.S1.Caption = Server1F.L101O1.Text
ROOM101.S2.Caption = Server1F.L101O2.Text
ROOM101.S3.Caption = Server1F.L101O3.Text
ROOM101.S4.Caption = Server1F.L101O4.Text
ROOM101.O1Delay.Caption = Server1F.OD101O1.Text & " Minute/s"
ROOM101.O2Delay.Caption = Server1F.OD101O2.Text & " Minute/s"
ROOM101.O3Delay.Caption = Server1F.OD101O3.Text & " Minute/s"
ROOM101.O4Delay.Caption = Server1F.OD101O4.Text & " Minute/s"
End Sub
ROOM102.S2.Caption = Server1F.L102O2.Text
ROOM102.S3.Caption = Server1F.L102O3.Text
ROOM102.S4.Caption = Server1F.L102O4.Text
ROOM102.O1Delay.Caption = Server1F.OD102O1.Text & " Minute/s"
ROOM102.O2Delay.Caption = Server1F.OD102O2.Text & " Minute/s"
ROOM102.O3Delay.Caption = Server1F.OD102O3.Text & " Minute/s"
ROOM102.O4Delay.Caption = Server1F.OD102O4.Text & " Minute/s"
End Sub
End Sub
Server1F.L104O3.Text = Server1F.DB104.Recordset.Fields("O3LABEL")
Server1F.L104O4.Text = Server1F.DB104.Recordset.Fields("O4LABEL")
Server1F.S104.Text = Server1F.DB104.Recordset.Fields("STATUS")
Server1F.C104.Text = Server1F.DB104.Recordset.Fields("COMPORT")
Server1F.O1S104.Text = Server1F.DB104.Recordset.Fields("O1STATUS")
Server1F.O2S104.Text = Server1F.DB104.Recordset.Fields("O2STATUS")
Server1F.O3S104.Text = Server1F.DB104.Recordset.Fields("O3STATUS")
Server1F.O4S104.Text = Server1F.DB104.Recordset.Fields("O4STATUS")
Server1F.OD104O1.Text = Server1F.DB104.Recordset.Fields("O1OUTPUTDELAY")
Server1F.OD104O2.Text = Server1F.DB104.Recordset.Fields("O2OUTPUTDELAY")
Server1F.OD104O3.Text = Server1F.DB104.Recordset.Fields("O3OUTPUTDELAY")
Server1F.OD104O4.Text = Server1F.DB104.Recordset.Fields("O4OUTPUTDELAY")
ROOM104.O1BTN.Caption = Server1F.L104O1.Text
ROOM104.O2BTN.Caption = Server1F.L104O2.Text
ROOM104.O3BTN.Caption = Server1F.L104O3.Text
ROOM104.O4BTN.Caption = Server1F.L104O4.Text
ROOM104.O1BTNOFF.Caption = Server1F.L104O1.Text
ROOM104.O2BTNOFF.Caption = Server1F.L104O2.Text
ROOM104.O3BTNOFF.Caption = Server1F.L104O3.Text
ROOM104.O4BTNOFF.Caption = Server1F.L104O4.Text
ROOM104.S1.Caption = Server1F.L104O1.Text
ROOM104.S2.Caption = Server1F.L104O2.Text
ROOM104.S3.Caption = Server1F.L104O3.Text
ROOM104.S4.Caption = Server1F.L104O4.Text
ROOM104.O1Delay.Caption = Server1F.OD104O1.Text & " Minute/s"
ROOM104.O2Delay.Caption = Server1F.OD104O2.Text & " Minute/s"
ROOM104.O3Delay.Caption = Server1F.OD104O3.Text & " Minute/s"
ROOM104.O4Delay.Caption = Server1F.OD104O4.Text & " Minute/s"
End Sub
ROOM105.O4BTN.Caption = Server1F.L105O4.Text
ROOM105.O1BTNOFF.Caption = Server1F.L105O1.Text
ROOM105.O2BTNOFF.Caption = Server1F.L105O2.Text
ROOM105.O3BTNOFF.Caption = Server1F.L105O3.Text
ROOM105.O4BTNOFF.Caption = Server1F.L105O4.Text
ROOM105.S1.Caption = Server1F.L105O1.Text
ROOM105.S2.Caption = Server1F.L105O2.Text
ROOM105.S3.Caption = Server1F.L105O3.Text
ROOM105.S4.Caption = Server1F.L105O4.Text
ROOM105.O1Delay.Caption = Server1F.OD105O1.Text & " Minute/s"
ROOM105.O2Delay.Caption = Server1F.OD105O2.Text & " Minute/s"
ROOM105.O3Delay.Caption = Server1F.OD105O3.Text & " Minute/s"
ROOM105.O4Delay.Caption = Server1F.OD105O4.Text & " Minute/s"
End Sub
End Sub
Server1F.LCLINICO2.Text = Server1F.DBCLINIC.Recordset.Fields("O2LABEL")
Server1F.LCLINICO3.Text = Server1F.DBCLINIC.Recordset.Fields("O3LABEL")
Server1F.LCLINICO4.Text = Server1F.DBCLINIC.Recordset.Fields("O4LABEL")
Server1F.SCLINIC.Text = Server1F.DBCLINIC.Recordset.Fields("STATUS")
Server1F.CCLINIC.Text = Server1F.DBCLINIC.Recordset.Fields("COMPORT")
Server1F.O1SCLINIC.Text = Server1F.DBCLINIC.Recordset.Fields("O1STATUS")
Server1F.O2SCLINIC.Text = Server1F.DBCLINIC.Recordset.Fields("O2STATUS")
Server1F.O3SCLINIC.Text = Server1F.DBCLINIC.Recordset.Fields("O3STATUS")
Server1F.O4SCLINIC.Text = Server1F.DBCLINIC.Recordset.Fields("O4STATUS")
Server1F.ODCLINICO1.Text =
Server1F.DBCLINIC.Recordset.Fields("O1OUTPUTDELAY")
Server1F.ODCLINICO2.Text =
Server1F.DBCLINIC.Recordset.Fields("O2OUTPUTDELAY")
Server1F.ODCLINICO3.Text =
Server1F.DBCLINIC.Recordset.Fields("O3OUTPUTDELAY")
Server1F.ODCLINICO4.Text =
Server1F.DBCLINIC.Recordset.Fields("O4OUTPUTDELAY")
ROOMCLINIC.O1BTN.Caption = Server1F.LCLINICO1.Text
ROOMCLINIC.O2BTN.Caption = Server1F.LCLINICO2.Text
ROOMCLINIC.O3BTN.Caption = Server1F.LCLINICO3.Text
ROOMCLINIC.O4BTN.Caption = Server1F.LCLINICO4.Text
ROOMCLINIC.O1BTNOFF.Caption = Server1F.LCLINICO1.Text
ROOMCLINIC.O2BTNOFF.Caption = Server1F.LCLINICO2.Text
ROOMCLINIC.O3BTNOFF.Caption = Server1F.LCLINICO3.Text
ROOMCLINIC.O4BTNOFF.Caption = Server1F.LCLINICO4.Text
ROOMCLINIC.S1.Caption = Server1F.LCLINICO1.Text
ROOMCLINIC.S2.Caption = Server1F.LCLINICO2.Text
ROOMCLINIC.S3.Caption = Server1F.LCLINICO3.Text
ROOMCLINIC.S4.Caption = Server1F.LCLINICO4.Text
ROOMCLINIC.O1Delay.Caption = Server1F.ODCLINICO1.Text & " Minute/s"
ROOMCLINIC.O2Delay.Caption = Server1F.ODCLINICO2.Text & " Minute/s"
ROOMCLINIC.O3Delay.Caption = Server1F.ODCLINICO3.Text & " Minute/s"
ROOMCLINIC.O4Delay.Caption = Server1F.ODCLINICO4.Text & " Minute/s"
End Sub
SS101.Text = Ado1F.Recordset.Fields("SWITCHSCHEDULE")
L101O1.Text = Ado1F.Recordset.Fields("O1LABEL")
L101O2.Text = Ado1F.Recordset.Fields("O2LABEL")
L101O3.Text = Ado1F.Recordset.Fields("O3LABEL")
L101O4.Text = Ado1F.Recordset.Fields("O4LABEL")
O1S101.Text = Ado1F.Recordset.Fields("O1STATUS")
O2S101.Text = Ado1F.Recordset.Fields("O2STATUS")
O3S101.Text = Ado1F.Recordset.Fields("O3STATUS")
O4S101.Text = Ado1F.Recordset.Fields("O4STATUS")
OD101O1.Text = Ado1F.Recordset.Fields("O1OUTPUTDELAY")
OD101O2.Text = Ado1F.Recordset.Fields("O2OUTPUTDELAY")
OD101O3.Text = Ado1F.Recordset.Fields("O3OUTPUTDELAY")
OD101O4.Text = Ado1F.Recordset.Fields("O4OUTPUTDELAY")
Ado1F.RecordSource = "Select * from Config where ROOMS='" + R102.Text + "'"
Ado1F.Refresh
S102.Text = Ado1F.Recordset.Fields("STATUS")
C102.Text = Ado1F.Recordset.Fields("COMPORT")
SS102.Text = Ado1F.Recordset.Fields("SWITCHSCHEDULE")
L102O1.Text = Ado1F.Recordset.Fields("O1LABEL")
L102O2.Text = Ado1F.Recordset.Fields("O2LABEL")
L102O3.Text = Ado1F.Recordset.Fields("O3LABEL")
L102O4.Text = Ado1F.Recordset.Fields("O4LABEL")
O1S102.Text = Ado1F.Recordset.Fields("O1STATUS")
O2S102.Text = Ado1F.Recordset.Fields("O2STATUS")
O3S102.Text = Ado1F.Recordset.Fields("O3STATUS")
O4S102.Text = Ado1F.Recordset.Fields("O4STATUS")
OD102O1.Text = Ado1F.Recordset.Fields("O1OUTPUTDELAY")
OD102O2.Text = Ado1F.Recordset.Fields("O2OUTPUTDELAY")
OD102O3.Text = Ado1F.Recordset.Fields("O3OUTPUTDELAY")
OD102O4.Text = Ado1F.Recordset.Fields("O4OUTPUTDELAY")
Ado1F.RecordSource = "Select * from Config where ROOMS='" + R103.Text + "'"
Ado1F.Refresh
S103.Text = Ado1F.Recordset.Fields("STATUS")
C103.Text = Ado1F.Recordset.Fields("COMPORT")
SS103.Text = Ado1F.Recordset.Fields("SWITCHSCHEDULE")
L103O1.Text = Ado1F.Recordset.Fields("O1LABEL")
L103O2.Text = Ado1F.Recordset.Fields("O2LABEL")
L103O3.Text = Ado1F.Recordset.Fields("O3LABEL")
L103O4.Text = Ado1F.Recordset.Fields("O4LABEL")
O1S103.Text = Ado1F.Recordset.Fields("O1STATUS")
O2S103.Text = Ado1F.Recordset.Fields("O2STATUS")
O3S103.Text = Ado1F.Recordset.Fields("O3STATUS")
O4S103.Text = Ado1F.Recordset.Fields("O4STATUS")
OD103O1.Text = Ado1F.Recordset.Fields("O1OUTPUTDELAY")
OD103O2.Text = Ado1F.Recordset.Fields("O2OUTPUTDELAY")
OD103O3.Text = Ado1F.Recordset.Fields("O3OUTPUTDELAY")
OD103O4.Text = Ado1F.Recordset.Fields("O4OUTPUTDELAY")
Ado1F.RecordSource = "Select * from Config where ROOMS='" + R104.Text + "'"
Ado1F.Refresh
S104.Text = Ado1F.Recordset.Fields("STATUS")
C104.Text = Ado1F.Recordset.Fields("COMPORT")
126
SS104.Text = Ado1F.Recordset.Fields("SWITCHSCHEDULE")
L104O1.Text = Ado1F.Recordset.Fields("O1LABEL")
L104O2.Text = Ado1F.Recordset.Fields("O2LABEL")
L104O3.Text = Ado1F.Recordset.Fields("O3LABEL")
L104O4.Text = Ado1F.Recordset.Fields("O4LABEL")
O1S104.Text = Ado1F.Recordset.Fields("O1STATUS")
O2S104.Text = Ado1F.Recordset.Fields("O2STATUS")
O3S104.Text = Ado1F.Recordset.Fields("O3STATUS")
O4S104.Text = Ado1F.Recordset.Fields("O4STATUS")
OD104O1.Text = Ado1F.Recordset.Fields("O1OUTPUTDELAY")
OD104O2.Text = Ado1F.Recordset.Fields("O2OUTPUTDELAY")
OD104O3.Text = Ado1F.Recordset.Fields("O3OUTPUTDELAY")
OD104O4.Text = Ado1F.Recordset.Fields("O4OUTPUTDELAY")
Ado1F.RecordSource = "Select * from Config where ROOMS='" + R105.Text + "'"
Ado1F.Refresh
S105.Text = Ado1F.Recordset.Fields("STATUS")
C105.Text = Ado1F.Recordset.Fields("COMPORT")
SS105.Text = Ado1F.Recordset.Fields("SWITCHSCHEDULE")
L105O1.Text = Ado1F.Recordset.Fields("O1LABEL")
L105O2.Text = Ado1F.Recordset.Fields("O2LABEL")
L105O3.Text = Ado1F.Recordset.Fields("O3LABEL")
L105O4.Text = Ado1F.Recordset.Fields("O4LABEL")
O1S105.Text = Ado1F.Recordset.Fields("O1STATUS")
O2S105.Text = Ado1F.Recordset.Fields("O2STATUS")
O3S105.Text = Ado1F.Recordset.Fields("O3STATUS")
O4S105.Text = Ado1F.Recordset.Fields("O4STATUS")
OD105O1.Text = Ado1F.Recordset.Fields("O1OUTPUTDELAY")
OD105O2.Text = Ado1F.Recordset.Fields("O2OUTPUTDELAY")
OD105O3.Text = Ado1F.Recordset.Fields("O3OUTPUTDELAY")
OD105O4.Text = Ado1F.Recordset.Fields("O4OUTPUTDELAY")
Ado1F.RecordSource = "Select * from Config where ROOMS='" + CR1F.Text + "'"
Ado1F.Refresh
S1FCR.Text = Ado1F.Recordset.Fields("STATUS")
C1FCR.Text = Ado1F.Recordset.Fields("COMPORT")
SS1FCR.Text = Ado1F.Recordset.Fields("SWITCHSCHEDULE")
L1FCRO1.Text = Ado1F.Recordset.Fields("O1LABEL")
L1FcrO2.Text = Ado1F.Recordset.Fields("O2LABEL")
L1FCRO3.Text = Ado1F.Recordset.Fields("O3LABEL")
L1FCRO4.Text = Ado1F.Recordset.Fields("O4LABEL")
O1S1FCR.Text = Ado1F.Recordset.Fields("O1STATUS")
O2S1FCR.Text = Ado1F.Recordset.Fields("O2STATUS")
O3S1FCR.Text = Ado1F.Recordset.Fields("O3STATUS")
O4S1FCR.Text = Ado1F.Recordset.Fields("O4STATUS")
OD1FCRO1.Text = Ado1F.Recordset.Fields("O1OUTPUTDELAY")
OD1FCRO2.Text = Ado1F.Recordset.Fields("O2OUTPUTDELAY")
OD1FCRO3.Text = Ado1F.Recordset.Fields("O3OUTPUTDELAY")
OD1FCRO4.Text = Ado1F.Recordset.Fields("O4OUTPUTDELAY")
Ado1F.RecordSource = "Select * from Config where ROOMS='" + HW1F.Text + "'"
Ado1F.Refresh
S1FHW.Text = Ado1F.Recordset.Fields("STATUS")
C1FHW.Text = Ado1F.Recordset.Fields("COMPORT")
127
SS1FHW.Text = Ado1F.Recordset.Fields("SWITCHSCHEDULE")
L1FHWO1.Text = Ado1F.Recordset.Fields("O1LABEL")
L1FHWO2.Text = Ado1F.Recordset.Fields("O2LABEL")
L1FHWO3.Text = Ado1F.Recordset.Fields("O3LABEL")
L1FHWO4.Text = Ado1F.Recordset.Fields("O4LABEL")
O1S1FHW.Text = Ado1F.Recordset.Fields("O1STATUS")
O2S1FHW.Text = Ado1F.Recordset.Fields("O2STATUS")
O3S1FHW.Text = Ado1F.Recordset.Fields("O3STATUS")
O4S1FHW.Text = Ado1F.Recordset.Fields("O4STATUS")
OD1FHWO1.Text = Ado1F.Recordset.Fields("O1OUTPUTDELAY")
OD1FHWO2.Text = Ado1F.Recordset.Fields("O2OUTPUTDELAY")
OD1FHWO3.Text = Ado1F.Recordset.Fields("O3OUTPUTDELAY")
OD1FHWO4.Text = Ado1F.Recordset.Fields("O4OUTPUTDELAY")
Ado1F.RecordSource = "Select * from Config where ROOMS='" + CLINIC.Text + "'"
Ado1F.Refresh
SCLINIC.Text = Ado1F.Recordset.Fields("STATUS")
CCLINIC.Text = Ado1F.Recordset.Fields("COMPORT")
SSCLINIC.Text = Ado1F.Recordset.Fields("SWITCHSCHEDULE")
LCLINICO1.Text = Ado1F.Recordset.Fields("O1LABEL")
LCLINICO2.Text = Ado1F.Recordset.Fields("O2LABEL")
LCLINICO3.Text = Ado1F.Recordset.Fields("O3LABEL")
LCLINICO4.Text = Ado1F.Recordset.Fields("O4LABEL")
O1SCLINIC.Text = Ado1F.Recordset.Fields("O1STATUS")
O2SCLINIC.Text = Ado1F.Recordset.Fields("O2STATUS")
O3SCLINIC.Text = Ado1F.Recordset.Fields("O3STATUS")
O4SCLINIC.Text = Ado1F.Recordset.Fields("O4STATUS")
ODCLINICO1.Text = Ado1F.Recordset.Fields("O1OUTPUTDELAY")
ODCLINICO2.Text = Ado1F.Recordset.Fields("O2OUTPUTDELAY")
ODCLINICO3.Text = Ado1F.Recordset.Fields("O3OUTPUTDELAY")
ODCLINICO4.Text = Ado1F.Recordset.Fields("O4OUTPUTDELAY")
End Sub
End Sub
Private Declare Function SendMessage Lib "user32" _
Alias "SendMessageA" (ByVal hWnd As Long, _
ByVal wMsg As Long, _
ByVal wParam As Long, _
lParam As Any) As Long
Private Declare Sub ReleaseCapture Lib "user32" ()
Const WM_NCLBUTTONDOWN = &HA1
Const HTCAPTION = 2
DeviceStatus.Text = .Recordset.Fields("STATUS")
End With
End If
End Sub
REFRESHSTATUS:
DataGrid1.Enabled = False
SetupBTN.Visible = False
SaveBTN.Visible = True
DeactivateBTN.Enabled = False
RoomSearch.Enabled = False
End If
End Sub
ComPorts.Enabled = True
RoomSearch.Enabled = False
DataGrid1.Enabled = False
SetupBTN.Visible = False
SaveBTN.Visible = True
DeactivateBTN.Enabled = False
End If
End Sub
Private Sub CloseBTN_Click()
Unload Me
MainMenu.Show
End Sub
O2OFF.Enabled = True
O3OFF.Enabled = True
O4OFF.Enabled = True
SaveBTN.Visible = True
SaveBTN.Caption = "Apply Changes"
End Sub
.HeadFont.Size = "11"
.HeadFont.Italic = True
.MarqueeStyle = dbgHighlightRowRaiseCell
End With
End Sub
O1OFF.Visible = False
End If
If O1DList.Text = "1" Then
O1Format.Caption = "MINUTE"
O1Format2.Caption = ""
End If
If O1DList.Text > 1 And O1DList.Text < 59 Then
O1Format.Caption = "MINUTES"
O1Format2.Caption = ""
End If
If O1DList.Text = "60" Then
O1Format.Caption = "MINUTES"
O1Format2.Caption = "/1 Hour"
End If
If O1DList.Text > 0 Then
O1OFF.Visible = True
End If
End Sub
O2OFF.Visible = False
End If
If O2DList.Text = "1" Then
O2Format.Caption = "MINUTE"
O2Format2.Caption = ""
End If
If O2DList.Text > 1 And O2DList.Text < 59 Then
O2Format.Caption = "MINUTES"
O2Format2.Caption = ""
End If
If O2DList.Text = "60" Then
O2Format.Caption = "MINUTES"
O2Format2.Caption = "/1 Hour"
End If
If O2DList.Text > 0 Then
O2OFF.Visible = True
End If
End Sub
End If
If O2DList.Text > 1 And O2DList.Text < 59 Then
O2Format.Caption = "MINUTES"
O2Format2.Caption = ""
End If
If O2DList.Text = "60" Then
O2Format.Caption = "MINUTES"
O2Format2.Caption = "/1 Hour"
End If
If O2DList.Text > 0 Then
O2OFF.Visible = True
End If
End Sub
End If
If O3DList.Text > 1 And O3DList.Text < 59 Then
O3Format.Caption = "MINUTES"
O3Format2.Caption = ""
End If
If O3DList.Text = "60" Then
O3Format.Caption = "MINUTES"
O3Format2.Caption = "/1 Hour"
End If
If O3DList.Text > 0 Then
O3OFF.Visible = True
End If
End Sub
O3OFF.Visible = True
End If
End Sub
O4OFF.Visible = True
End If
End Sub
O4OFF.Visible = True
End If
End Sub
If Check5.Value = 1 Then
.Recordset.Fields("FRIDAY") = "TRUE"
End If
If Check5.Value = 0 Then
.Recordset.Fields("FRIDAY") = "FALSE"
End If
If Check6.Value = 1 Then
.Recordset.Fields("SATURDAY") = "TRUE"
End If
If Check6.Value = 0 Then
.Recordset.Fields("SATURDAY") = "FALSE"
End If
If Check7.Value = 1 Then
.Recordset.Fields("SUNDAY") = "TRUE"
End If
If Check7.Value = 0 Then
.Recordset.Fields("SUNDAY") = "FALSE"
End If
.Recordset.Fields("TIME ON") = TimeON.Text
.Recordset.Fields("TIME OFF") = TimeOFF.Text
.Recordset.Fields("ONHOURS") = ONHOURS.Text
.Recordset.Fields("ONMINUTES") = ONMINUTES.Text
.Recordset.Fields("ONAMPM") = ONAMPM.Text
.Recordset.Fields("OFFHOURS") = OFFHOURS.Text
.Recordset.Fields("OFFMINUTES") = OFFMINUTES.Text
.Recordset.Fields("OFFAMPM") = OFFAMPM.Text
.Recordset.Update
End With
MsgBox "Scheduling Activated!.", vbInformation, "APPLIANCE WIRING CONTROL
SYSTEM"
Check1.Enabled = False
Check2.Enabled = False
Check3.Enabled = False
Check4.Enabled = False
Check5.Enabled = False
Check6.Enabled = False
Check7.Enabled = False
TimeONSCHED.Enabled = False
TimeONMANUAL.Enabled = False
TimeOFFSCHED.Enabled = False
TimeOFFMANUAL.Enabled = False
SchedulingStatus.Enabled = False
ApplyBTN.Visible = False
ROOMBTN.Visible = True
TimeONHOURS.Enabled = False
TimeONMINUTES.Enabled = False
TimeONAMPM.Enabled = False
TimeOFFHOURS.Enabled = False
TimeOFFMINUTES.Enabled = False
TimeOFFAMPM.Enabled = False
Combo1.Enabled = True
148
SchedulingCommands.SchedTimer.Value = True
GoTo NEWLOAD
End If
End If
If SchedulingStatus.Text = "DEACTIVATED" Then
With RoomDB
.Recordset.Fields("SWITCHSCHEDULE") = SchedulingStatus.Text
.Recordset.Fields("TIME ON") = "MANUAL"
.Recordset.Fields("TIME OFF") = "MANUAL"
.Recordset.Fields("ONHOURS") = "1"
.Recordset.Fields("ONMINUTES") = "00"
.Recordset.Fields("ONAMPM") = "AM"
.Recordset.Fields("OFFHOURS") = "1"
.Recordset.Fields("OFFMINUTES") = "00"
.Recordset.Fields("OFFAMPM") = "AM"
.Recordset.Fields("MONDAY") = "FALSE"
.Recordset.Fields("TUESDAY") = "FALSE"
.Recordset.Fields("WEDNESDAY") = "FALSE"
.Recordset.Fields("THURSDAY") = "FALSE"
.Recordset.Fields("FRIDAY") = "FALSE"
.Recordset.Fields("SATURDAY") = "FALSE"
.Recordset.Fields("SUNDAY") = "FALSE"
.Recordset.Update
End With
MsgBox "Scheduling Deactivated!.", vbInformation, "APPLIANCE WIRING CONTROL
SYSTEM"
Check1.Enabled = False
Check2.Enabled = False
Check3.Enabled = False
Check4.Enabled = False
Check5.Enabled = False
Check6.Enabled = False
Check7.Enabled = False
TimeONSCHED.Enabled = False
TimeONMANUAL.Enabled = False
TimeOFFSCHED.Enabled = False
TimeOFFMANUAL.Enabled = False
SchedulingStatus.Enabled = False
ApplyBTN.Visible = False
ROOMBTN.Visible = True
TimeONHOURS.Enabled = False
TimeONMINUTES.Enabled = False
TimeONAMPM.Enabled = False
TimeOFFHOURS.Enabled = False
TimeOFFMINUTES.Enabled = False
TimeOFFAMPM.Enabled = False
SchedulingCommands.SchedTimer.Value = True
Combo1.Enabled = True
GoTo NEWLOAD
End If
Exit Sub
149
NEWLOAD:
If Combo1.Text = "ROOM 101" Then
RoomDB.RecordSource = "Select * from Config where ROOMS='" + "101" + "'"
RoomDB.Refresh
SchedulingStatus.Text = RoomDB.Recordset.Fields("SwitchSchedule")
MondayTxt.Text = RoomDB.Recordset.Fields("MONDAY")
TuesdayTxt.Text = RoomDB.Recordset.Fields("TUESDAY")
WednesdayTxt.Text = RoomDB.Recordset.Fields("WEDNESDAY")
ThursdayTxt.Text = RoomDB.Recordset.Fields("THURSDAY")
FridayTxt.Text = RoomDB.Recordset.Fields("FRIDAY")
SaturdayTxt.Text = RoomDB.Recordset.Fields("SATURDAY")
SundayTxt.Text = RoomDB.Recordset.Fields("SUNDAY")
StatusTxt.Text = RoomDB.Recordset.Fields("STATUS")
TimeON.Text = RoomDB.Recordset.Fields("TIME ON")
TimeOFF.Text = RoomDB.Recordset.Fields("TIME OFF")
ONHOURS.Text = RoomDB.Recordset.Fields("ONHOURS")
ONMINUTES.Text = RoomDB.Recordset.Fields("ONMINUTES")
ONAMPM.Text = RoomDB.Recordset.Fields("ONAMPM")
OFFHOURS.Text = RoomDB.Recordset.Fields("OFFHOURS")
OFFMINUTES.Text = RoomDB.Recordset.Fields("OFFMINUTES")
OFFAMPM.Text = RoomDB.Recordset.Fields("OFFAMPM")
TimeON.Text = RoomDB.Recordset.Fields("TIME ON")
TimeOFF.Text = RoomDB.Recordset.Fields("TIME OFF")
GoSub SubDATA
ElseIf Combo1.Text = "ROOM 102" Then
RoomDB.RecordSource = "Select * from Config where ROOMS='" + "102" + "'"
RoomDB.Refresh
SchedulingStatus.Text = RoomDB.Recordset.Fields("SwitchSchedule")
MondayTxt.Text = RoomDB.Recordset.Fields("MONDAY")
TuesdayTxt.Text = RoomDB.Recordset.Fields("TUESDAY")
WednesdayTxt.Text = RoomDB.Recordset.Fields("WEDNESDAY")
ThursdayTxt.Text = RoomDB.Recordset.Fields("THURSDAY")
FridayTxt.Text = RoomDB.Recordset.Fields("FRIDAY")
SaturdayTxt.Text = RoomDB.Recordset.Fields("SATURDAY")
SundayTxt.Text = RoomDB.Recordset.Fields("SUNDAY")
StatusTxt.Text = RoomDB.Recordset.Fields("STATUS")
TimeON.Text = RoomDB.Recordset.Fields("TIME ON")
TimeOFF.Text = RoomDB.Recordset.Fields("TIME OFF")
ONHOURS.Text = RoomDB.Recordset.Fields("ONHOURS")
ONMINUTES.Text = RoomDB.Recordset.Fields("ONMINUTES")
ONAMPM.Text = RoomDB.Recordset.Fields("ONAMPM")
OFFHOURS.Text = RoomDB.Recordset.Fields("OFFHOURS")
OFFMINUTES.Text = RoomDB.Recordset.Fields("OFFMINUTES")
OFFAMPM.Text = RoomDB.Recordset.Fields("OFFAMPM")
TimeON.Text = RoomDB.Recordset.Fields("TIME ON")
TimeOFF.Text = RoomDB.Recordset.Fields("TIME OFF")
GoSub SubDATA
ElseIf Combo1.Text = "ROOM 103" Then
RoomDB.RecordSource = "Select * from Config where ROOMS='" + "103" + "'"
RoomDB.Refresh
150
SchedulingStatus.Text = RoomDB.Recordset.Fields("SwitchSchedule")
MondayTxt.Text = RoomDB.Recordset.Fields("MONDAY")
TuesdayTxt.Text = RoomDB.Recordset.Fields("TUESDAY")
WednesdayTxt.Text = RoomDB.Recordset.Fields("WEDNESDAY")
ThursdayTxt.Text = RoomDB.Recordset.Fields("THURSDAY")
FridayTxt.Text = RoomDB.Recordset.Fields("FRIDAY")
SaturdayTxt.Text = RoomDB.Recordset.Fields("SATURDAY")
SundayTxt.Text = RoomDB.Recordset.Fields("SUNDAY")
StatusTxt.Text = RoomDB.Recordset.Fields("STATUS")
TimeON.Text = RoomDB.Recordset.Fields("TIME ON")
TimeOFF.Text = RoomDB.Recordset.Fields("TIME OFF")
ONHOURS.Text = RoomDB.Recordset.Fields("ONHOURS")
ONMINUTES.Text = RoomDB.Recordset.Fields("ONMINUTES")
ONAMPM.Text = RoomDB.Recordset.Fields("ONAMPM")
OFFHOURS.Text = RoomDB.Recordset.Fields("OFFHOURS")
OFFMINUTES.Text = RoomDB.Recordset.Fields("OFFMINUTES")
OFFAMPM.Text = RoomDB.Recordset.Fields("OFFAMPM")
TimeON.Text = RoomDB.Recordset.Fields("TIME ON")
TimeOFF.Text = RoomDB.Recordset.Fields("TIME OFF")
GoSub SubDATA
ElseIf Combo1.Text = "ROOM 104" Then
RoomDB.RecordSource = "Select * from Config where ROOMS='" + "104" + "'"
RoomDB.Refresh
SchedulingStatus.Text = RoomDB.Recordset.Fields("SwitchSchedule")
MondayTxt.Text = RoomDB.Recordset.Fields("MONDAY")
TuesdayTxt.Text = RoomDB.Recordset.Fields("TUESDAY")
WednesdayTxt.Text = RoomDB.Recordset.Fields("WEDNESDAY")
ThursdayTxt.Text = RoomDB.Recordset.Fields("THURSDAY")
FridayTxt.Text = RoomDB.Recordset.Fields("FRIDAY")
SaturdayTxt.Text = RoomDB.Recordset.Fields("SATURDAY")
SundayTxt.Text = RoomDB.Recordset.Fields("SUNDAY")
StatusTxt.Text = RoomDB.Recordset.Fields("STATUS")
TimeON.Text = RoomDB.Recordset.Fields("TIME ON")
TimeOFF.Text = RoomDB.Recordset.Fields("TIME OFF")
ONHOURS.Text = RoomDB.Recordset.Fields("ONHOURS")
ONMINUTES.Text = RoomDB.Recordset.Fields("ONMINUTES")
ONAMPM.Text = RoomDB.Recordset.Fields("ONAMPM")
OFFHOURS.Text = RoomDB.Recordset.Fields("OFFHOURS")
OFFMINUTES.Text = RoomDB.Recordset.Fields("OFFMINUTES")
OFFAMPM.Text = RoomDB.Recordset.Fields("OFFAMPM")
TimeON.Text = RoomDB.Recordset.Fields("TIME ON")
TimeOFF.Text = RoomDB.Recordset.Fields("TIME OFF")
GoSub SubDATA
ElseIf Combo1.Text = "ROOM 105" Then
RoomDB.RecordSource = "Select * from Config where ROOMS='" + "105" + "'"
RoomDB.Refresh
SchedulingStatus.Text = RoomDB.Recordset.Fields("SwitchSchedule")
MondayTxt.Text = RoomDB.Recordset.Fields("MONDAY")
TuesdayTxt.Text = RoomDB.Recordset.Fields("TUESDAY")
WednesdayTxt.Text = RoomDB.Recordset.Fields("WEDNESDAY")
ThursdayTxt.Text = RoomDB.Recordset.Fields("THURSDAY")
151
FridayTxt.Text = RoomDB.Recordset.Fields("FRIDAY")
SaturdayTxt.Text = RoomDB.Recordset.Fields("SATURDAY")
SundayTxt.Text = RoomDB.Recordset.Fields("SUNDAY")
StatusTxt.Text = RoomDB.Recordset.Fields("STATUS")
TimeON.Text = RoomDB.Recordset.Fields("TIME ON")
TimeOFF.Text = RoomDB.Recordset.Fields("TIME OFF")
ONHOURS.Text = RoomDB.Recordset.Fields("ONHOURS")
ONMINUTES.Text = RoomDB.Recordset.Fields("ONMINUTES")
ONAMPM.Text = RoomDB.Recordset.Fields("ONAMPM")
OFFHOURS.Text = RoomDB.Recordset.Fields("OFFHOURS")
OFFMINUTES.Text = RoomDB.Recordset.Fields("OFFMINUTES")
OFFAMPM.Text = RoomDB.Recordset.Fields("OFFAMPM")
TimeON.Text = RoomDB.Recordset.Fields("TIME ON")
TimeOFF.Text = RoomDB.Recordset.Fields("TIME OFF")
GoSub SubDATA
ElseIf Combo1.Text = "1F COMFORT ROOM" Then
RoomDB.RecordSource = "Select * from Config where ROOMS='" + "1F CR" + "'"
RoomDB.Refresh
SchedulingStatus.Text = RoomDB.Recordset.Fields("SwitchSchedule")
MondayTxt.Text = RoomDB.Recordset.Fields("MONDAY")
TuesdayTxt.Text = RoomDB.Recordset.Fields("TUESDAY")
WednesdayTxt.Text = RoomDB.Recordset.Fields("WEDNESDAY")
ThursdayTxt.Text = RoomDB.Recordset.Fields("THURSDAY")
FridayTxt.Text = RoomDB.Recordset.Fields("FRIDAY")
SaturdayTxt.Text = RoomDB.Recordset.Fields("SATURDAY")
SundayTxt.Text = RoomDB.Recordset.Fields("SUNDAY")
StatusTxt.Text = RoomDB.Recordset.Fields("STATUS")
TimeON.Text = RoomDB.Recordset.Fields("TIME ON")
TimeOFF.Text = RoomDB.Recordset.Fields("TIME OFF")
ONHOURS.Text = RoomDB.Recordset.Fields("ONHOURS")
ONMINUTES.Text = RoomDB.Recordset.Fields("ONMINUTES")
ONAMPM.Text = RoomDB.Recordset.Fields("ONAMPM")
OFFHOURS.Text = RoomDB.Recordset.Fields("OFFHOURS")
OFFMINUTES.Text = RoomDB.Recordset.Fields("OFFMINUTES")
OFFAMPM.Text = RoomDB.Recordset.Fields("OFFAMPM")
TimeON.Text = RoomDB.Recordset.Fields("TIME ON")
TimeOFF.Text = RoomDB.Recordset.Fields("TIME OFF")
GoSub SubDATA
ElseIf Combo1.Text = "1F HALLWAY" Then
RoomDB.RecordSource = "Select * from Config where ROOMS='" + "1F HALLWAY" +
"'"
RoomDB.Refresh
SchedulingStatus.Text = RoomDB.Recordset.Fields("SwitchSchedule")
MondayTxt.Text = RoomDB.Recordset.Fields("MONDAY")
TuesdayTxt.Text = RoomDB.Recordset.Fields("TUESDAY")
WednesdayTxt.Text = RoomDB.Recordset.Fields("WEDNESDAY")
ThursdayTxt.Text = RoomDB.Recordset.Fields("THURSDAY")
FridayTxt.Text = RoomDB.Recordset.Fields("FRIDAY")
SaturdayTxt.Text = RoomDB.Recordset.Fields("SATURDAY")
SundayTxt.Text = RoomDB.Recordset.Fields("SUNDAY")
StatusTxt.Text = RoomDB.Recordset.Fields("STATUS")
152
SubDATA:
ROOMLABEL.Caption = Combo1.Text
If SchedulingStatus.Text = "DEACTIVATED" Then
ROOMBTN.Caption = "SET SCHEDULE"
If MondayTxt.Text = "TRUE" Then
Check1.Value = 1
End If
If MondayTxt.Text = "FALSE" Then
Check1.Value = 0
End If
If TuesdayTxt.Text = "TRUE" Then
Check2.Value = 1
End If
If TuesdayTxt.Text = "FALSE" Then
153
Check2.Value = 0
End If
If WednesdayTxt.Text = "TRUE" Then
Check3.Value = 1
End If
If WednesdayTxt.Text = "FALSE" Then
Check3.Value = 0
End If
If ThursdayTxt.Text = "TRUE" Then
Check4.Value = 1
End If
If ThursdayTxt.Text = "FALSE" Then
Check4.Value = 0
End If
If FridayTxt.Text = "TRUE" Then
Check5.Value = 1
End If
If FridayTxt.Text = "FALSE" Then
Check5.Value = 0
End If
If SaturdayTxt.Text = "TRUE" Then
Check6.Value = 1
End If
If SaturdayTxt.Text = "FALSE" Then
Check6.Value = 0
End If
If SundayTxt.Text = "TRUE" Then
Check7.Value = 1
End If
If SundayTxt.Text = "FALSE" Then
Check7.Value = 0
End If
End If
If SchedulingStatus.Text = "ACTIVATED" Then
ROOMBTN.Caption = "EDIT SCHEDULE"
If MondayTxt.Text = "TRUE" Then
Check1.Value = 1
End If
If MondayTxt.Text = "FALSE" Then
Check1.Value = 0
End If
If TuesdayTxt.Text = "TRUE" Then
Check2.Value = 1
End If
If TuesdayTxt.Text = "FALSE" Then
Check2.Value = 0
End If
If WednesdayTxt.Text = "TRUE" Then
Check3.Value = 1
End If
If WednesdayTxt.Text = "FALSE" Then
154
Check3.Value = 0
End If
If ThursdayTxt.Text = "TRUE" Then
Check4.Value = 1
End If
If ThursdayTxt.Text = "FALSE" Then
Check4.Value = 0
End If
If FridayTxt.Text = "TRUE" Then
Check5.Value = 1
End If
If FridayTxt.Text = "FALSE" Then
Check5.Value = 0
End If
If SaturdayTxt.Text = "TRUE" Then
Check6.Value = 1
End If
If SaturdayTxt.Text = "FALSE" Then
Check6.Value = 0
End If
If SundayTxt.Text = "TRUE" Then
Check7.Value = 1
End If
If SundayTxt.Text = "FALSE" Then
Check7.Value = 0
End If
End If
End Sub
End If
If Check3.Value = 0 Then
WednesdayTxt.Text = "FALSE"
End If
End Sub
RoomDB.Refresh
SchedulingStatus.Text = RoomDB.Recordset.Fields("SwitchSchedule")
MondayTxt.Text = RoomDB.Recordset.Fields("MONDAY")
TuesdayTxt.Text = RoomDB.Recordset.Fields("TUESDAY")
WednesdayTxt.Text = RoomDB.Recordset.Fields("WEDNESDAY")
ThursdayTxt.Text = RoomDB.Recordset.Fields("THURSDAY")
FridayTxt.Text = RoomDB.Recordset.Fields("FRIDAY")
SaturdayTxt.Text = RoomDB.Recordset.Fields("SATURDAY")
SundayTxt.Text = RoomDB.Recordset.Fields("SUNDAY")
StatusTxt.Text = RoomDB.Recordset.Fields("STATUS")
TimeON.Text = RoomDB.Recordset.Fields("TIME ON")
TimeOFF.Text = RoomDB.Recordset.Fields("TIME OFF")
ONHOURS.Text = RoomDB.Recordset.Fields("ONHOURS")
ONMINUTES.Text = RoomDB.Recordset.Fields("ONMINUTES")
ONAMPM.Text = RoomDB.Recordset.Fields("ONAMPM")
OFFHOURS.Text = RoomDB.Recordset.Fields("OFFHOURS")
OFFMINUTES.Text = RoomDB.Recordset.Fields("OFFMINUTES")
OFFAMPM.Text = RoomDB.Recordset.Fields("OFFAMPM")
TimeON.Text = RoomDB.Recordset.Fields("TIME ON")
TimeOFF.Text = RoomDB.Recordset.Fields("TIME OFF")
GoSub SubDATA
ElseIf Combo1.Text = "ROOM 102" Then
RoomDB.RecordSource = "Select * from Config where ROOMS='" + "102" + "'"
RoomDB.Refresh
SchedulingStatus.Text = RoomDB.Recordset.Fields("SwitchSchedule")
MondayTxt.Text = RoomDB.Recordset.Fields("MONDAY")
TuesdayTxt.Text = RoomDB.Recordset.Fields("TUESDAY")
WednesdayTxt.Text = RoomDB.Recordset.Fields("WEDNESDAY")
ThursdayTxt.Text = RoomDB.Recordset.Fields("THURSDAY")
FridayTxt.Text = RoomDB.Recordset.Fields("FRIDAY")
SaturdayTxt.Text = RoomDB.Recordset.Fields("SATURDAY")
SundayTxt.Text = RoomDB.Recordset.Fields("SUNDAY")
StatusTxt.Text = RoomDB.Recordset.Fields("STATUS")
TimeON.Text = RoomDB.Recordset.Fields("TIME ON")
TimeOFF.Text = RoomDB.Recordset.Fields("TIME OFF")
ONHOURS.Text = RoomDB.Recordset.Fields("ONHOURS")
ONMINUTES.Text = RoomDB.Recordset.Fields("ONMINUTES")
ONAMPM.Text = RoomDB.Recordset.Fields("ONAMPM")
OFFHOURS.Text = RoomDB.Recordset.Fields("OFFHOURS")
OFFMINUTES.Text = RoomDB.Recordset.Fields("OFFMINUTES")
OFFAMPM.Text = RoomDB.Recordset.Fields("OFFAMPM")
TimeON.Text = RoomDB.Recordset.Fields("TIME ON")
TimeOFF.Text = RoomDB.Recordset.Fields("TIME OFF")
GoSub SubDATA
ElseIf Combo1.Text = "ROOM 103" Then
RoomDB.RecordSource = "Select * from Config where ROOMS='" + "103" + "'"
RoomDB.Refresh
SchedulingStatus.Text = RoomDB.Recordset.Fields("SwitchSchedule")
MondayTxt.Text = RoomDB.Recordset.Fields("MONDAY")
TuesdayTxt.Text = RoomDB.Recordset.Fields("TUESDAY")
WednesdayTxt.Text = RoomDB.Recordset.Fields("WEDNESDAY")
157
ThursdayTxt.Text = RoomDB.Recordset.Fields("THURSDAY")
FridayTxt.Text = RoomDB.Recordset.Fields("FRIDAY")
SaturdayTxt.Text = RoomDB.Recordset.Fields("SATURDAY")
SundayTxt.Text = RoomDB.Recordset.Fields("SUNDAY")
StatusTxt.Text = RoomDB.Recordset.Fields("STATUS")
TimeON.Text = RoomDB.Recordset.Fields("TIME ON")
TimeOFF.Text = RoomDB.Recordset.Fields("TIME OFF")
ONHOURS.Text = RoomDB.Recordset.Fields("ONHOURS")
ONMINUTES.Text = RoomDB.Recordset.Fields("ONMINUTES")
ONAMPM.Text = RoomDB.Recordset.Fields("ONAMPM")
OFFHOURS.Text = RoomDB.Recordset.Fields("OFFHOURS")
OFFMINUTES.Text = RoomDB.Recordset.Fields("OFFMINUTES")
OFFAMPM.Text = RoomDB.Recordset.Fields("OFFAMPM")
TimeON.Text = RoomDB.Recordset.Fields("TIME ON")
TimeOFF.Text = RoomDB.Recordset.Fields("TIME OFF")
GoSub SubDATA
ElseIf Combo1.Text = "ROOM 104" Then
RoomDB.RecordSource = "Select * from Config where ROOMS='" + "104" + "'"
RoomDB.Refresh
SchedulingStatus.Text = RoomDB.Recordset.Fields("SwitchSchedule")
MondayTxt.Text = RoomDB.Recordset.Fields("MONDAY")
TuesdayTxt.Text = RoomDB.Recordset.Fields("TUESDAY")
WednesdayTxt.Text = RoomDB.Recordset.Fields("WEDNESDAY")
ThursdayTxt.Text = RoomDB.Recordset.Fields("THURSDAY")
FridayTxt.Text = RoomDB.Recordset.Fields("FRIDAY")
SaturdayTxt.Text = RoomDB.Recordset.Fields("SATURDAY")
SundayTxt.Text = RoomDB.Recordset.Fields("SUNDAY")
StatusTxt.Text = RoomDB.Recordset.Fields("STATUS")
TimeON.Text = RoomDB.Recordset.Fields("TIME ON")
TimeOFF.Text = RoomDB.Recordset.Fields("TIME OFF")
ONHOURS.Text = RoomDB.Recordset.Fields("ONHOURS")
ONMINUTES.Text = RoomDB.Recordset.Fields("ONMINUTES")
ONAMPM.Text = RoomDB.Recordset.Fields("ONAMPM")
OFFHOURS.Text = RoomDB.Recordset.Fields("OFFHOURS")
OFFMINUTES.Text = RoomDB.Recordset.Fields("OFFMINUTES")
OFFAMPM.Text = RoomDB.Recordset.Fields("OFFAMPM")
TimeON.Text = RoomDB.Recordset.Fields("TIME ON")
TimeOFF.Text = RoomDB.Recordset.Fields("TIME OFF")
GoSub SubDATA
ElseIf Combo1.Text = "ROOM 105" Then
RoomDB.RecordSource = "Select * from Config where ROOMS='" + "105" + "'"
RoomDB.Refresh
SchedulingStatus.Text = RoomDB.Recordset.Fields("SwitchSchedule")
MondayTxt.Text = RoomDB.Recordset.Fields("MONDAY")
TuesdayTxt.Text = RoomDB.Recordset.Fields("TUESDAY")
WednesdayTxt.Text = RoomDB.Recordset.Fields("WEDNESDAY")
ThursdayTxt.Text = RoomDB.Recordset.Fields("THURSDAY")
FridayTxt.Text = RoomDB.Recordset.Fields("FRIDAY")
SaturdayTxt.Text = RoomDB.Recordset.Fields("SATURDAY")
SundayTxt.Text = RoomDB.Recordset.Fields("SUNDAY")
StatusTxt.Text = RoomDB.Recordset.Fields("STATUS")
158
ONAMPM.Text = RoomDB.Recordset.Fields("ONAMPM")
OFFHOURS.Text = RoomDB.Recordset.Fields("OFFHOURS")
OFFMINUTES.Text = RoomDB.Recordset.Fields("OFFMINUTES")
OFFAMPM.Text = RoomDB.Recordset.Fields("OFFAMPM")
TimeON.Text = RoomDB.Recordset.Fields("TIME ON")
TimeOFF.Text = RoomDB.Recordset.Fields("TIME OFF")
GoSub SubDATA
ElseIf Combo1.Text = "CLINIC" Then
RoomDB.RecordSource = "Select * from Config where ROOMS='" + "CLINIC" + "'"
RoomDB.Refresh
SchedulingStatus.Text = RoomDB.Recordset.Fields("SwitchSchedule")
MondayTxt.Text = RoomDB.Recordset.Fields("MONDAY")
TuesdayTxt.Text = RoomDB.Recordset.Fields("TUESDAY")
WednesdayTxt.Text = RoomDB.Recordset.Fields("WEDNESDAY")
ThursdayTxt.Text = RoomDB.Recordset.Fields("THURSDAY")
FridayTxt.Text = RoomDB.Recordset.Fields("FRIDAY")
SaturdayTxt.Text = RoomDB.Recordset.Fields("SATURDAY")
SundayTxt.Text = RoomDB.Recordset.Fields("SUNDAY")
StatusTxt.Text = RoomDB.Recordset.Fields("STATUS")
TimeON.Text = RoomDB.Recordset.Fields("TIME ON")
TimeOFF.Text = RoomDB.Recordset.Fields("TIME OFF")
ONHOURS.Text = RoomDB.Recordset.Fields("ONHOURS")
ONMINUTES.Text = RoomDB.Recordset.Fields("ONMINUTES")
ONAMPM.Text = RoomDB.Recordset.Fields("ONAMPM")
OFFHOURS.Text = RoomDB.Recordset.Fields("OFFHOURS")
OFFMINUTES.Text = RoomDB.Recordset.Fields("OFFMINUTES")
OFFAMPM.Text = RoomDB.Recordset.Fields("OFFAMPM")
TimeON.Text = RoomDB.Recordset.Fields("TIME ON")
TimeOFF.Text = RoomDB.Recordset.Fields("TIME OFF")
GoSub SubDATA
End If
Exit Sub
SubDATA:
ROOMLABEL.Caption = Combo1.Text
If SchedulingStatus.Text = "DEACTIVATED" Then
ROOMBTN.Caption = "SET SCHEDULE"
End If
If SchedulingStatus.Text = "ACTIVATED" Then
ROOMBTN.Caption = "EDIT SCHEDULE"
End If
If MondayTxt.Text = "TRUE" Then
Check1.Value = 1
End If
If MondayTxt.Text = "FALSE" Then
Check1.Value = 0
End If
If TuesdayTxt.Text = "TRUE" Then
Check2.Value = 1
End If
If TuesdayTxt.Text = "FALSE" Then
160
Check2.Value = 0
End If
If WednesdayTxt.Text = "TRUE" Then
Check3.Value = 1
End If
If WednesdayTxt.Text = "FALSE" Then
Check3.Value = 0
End If
If ThursdayTxt.Text = "TRUE" Then
Check4.Value = 1
End If
If ThursdayTxt.Text = "FALSE" Then
Check4.Value = 0
End If
If FridayTxt.Text = "TRUE" Then
Check5.Value = 1
End If
If FridayTxt.Text = "FALSE" Then
Check5.Value = 0
End If
If SaturdayTxt.Text = "TRUE" Then
Check6.Value = 1
End If
If SaturdayTxt.Text = "FALSE" Then
Check6.Value = 0
End If
If SundayTxt.Text = "TRUE" Then
Check7.Value = 1
End If
If SundayTxt.Text = "FALSE" Then
Check7.Value = 0
End If
End Sub
ONAMPM.Text = RoomDB.Recordset.Fields("ONAMPM")
OFFHOURS.Text = RoomDB.Recordset.Fields("OFFHOURS")
OFFMINUTES.Text = RoomDB.Recordset.Fields("OFFMINUTES")
OFFAMPM.Text = RoomDB.Recordset.Fields("OFFAMPM")
TimeON.Text = RoomDB.Recordset.Fields("TIME ON")
TimeOFF.Text = RoomDB.Recordset.Fields("TIME OFF")
GoSub SubDATA
ElseIf Combo1.Text = "ROOM 102" Then
RoomDB.RecordSource = "Select * from Config where ROOMS='" + "102" + "'"
RoomDB.Refresh
SchedulingStatus.Text = RoomDB.Recordset.Fields("SwitchSchedule")
MondayTxt.Text = RoomDB.Recordset.Fields("MONDAY")
TuesdayTxt.Text = RoomDB.Recordset.Fields("TUESDAY")
WednesdayTxt.Text = RoomDB.Recordset.Fields("WEDNESDAY")
ThursdayTxt.Text = RoomDB.Recordset.Fields("THURSDAY")
FridayTxt.Text = RoomDB.Recordset.Fields("FRIDAY")
SaturdayTxt.Text = RoomDB.Recordset.Fields("SATURDAY")
SundayTxt.Text = RoomDB.Recordset.Fields("SUNDAY")
StatusTxt.Text = RoomDB.Recordset.Fields("STATUS")
TimeON.Text = RoomDB.Recordset.Fields("TIME ON")
TimeOFF.Text = RoomDB.Recordset.Fields("TIME OFF")
ONHOURS.Text = RoomDB.Recordset.Fields("ONHOURS")
ONMINUTES.Text = RoomDB.Recordset.Fields("ONMINUTES")
ONAMPM.Text = RoomDB.Recordset.Fields("ONAMPM")
OFFHOURS.Text = RoomDB.Recordset.Fields("OFFHOURS")
OFFMINUTES.Text = RoomDB.Recordset.Fields("OFFMINUTES")
OFFAMPM.Text = RoomDB.Recordset.Fields("OFFAMPM")
TimeON.Text = RoomDB.Recordset.Fields("TIME ON")
TimeOFF.Text = RoomDB.Recordset.Fields("TIME OFF")
GoSub SubDATA
ElseIf Combo1.Text = "ROOM 103" Then
RoomDB.RecordSource = "Select * from Config where ROOMS='" + "103" + "'"
RoomDB.Refresh
SchedulingStatus.Text = RoomDB.Recordset.Fields("SwitchSchedule")
MondayTxt.Text = RoomDB.Recordset.Fields("MONDAY")
TuesdayTxt.Text = RoomDB.Recordset.Fields("TUESDAY")
WednesdayTxt.Text = RoomDB.Recordset.Fields("WEDNESDAY")
ThursdayTxt.Text = RoomDB.Recordset.Fields("THURSDAY")
FridayTxt.Text = RoomDB.Recordset.Fields("FRIDAY")
SaturdayTxt.Text = RoomDB.Recordset.Fields("SATURDAY")
SundayTxt.Text = RoomDB.Recordset.Fields("SUNDAY")
StatusTxt.Text = RoomDB.Recordset.Fields("STATUS")
TimeON.Text = RoomDB.Recordset.Fields("TIME ON")
TimeOFF.Text = RoomDB.Recordset.Fields("TIME OFF")
ONHOURS.Text = RoomDB.Recordset.Fields("ONHOURS")
ONMINUTES.Text = RoomDB.Recordset.Fields("ONMINUTES")
ONAMPM.Text = RoomDB.Recordset.Fields("ONAMPM")
OFFHOURS.Text = RoomDB.Recordset.Fields("OFFHOURS")
OFFMINUTES.Text = RoomDB.Recordset.Fields("OFFMINUTES")
OFFAMPM.Text = RoomDB.Recordset.Fields("OFFAMPM")
TimeON.Text = RoomDB.Recordset.Fields("TIME ON")
162
SchedulingStatus.Text = RoomDB.Recordset.Fields("SwitchSchedule")
MondayTxt.Text = RoomDB.Recordset.Fields("MONDAY")
TuesdayTxt.Text = RoomDB.Recordset.Fields("TUESDAY")
WednesdayTxt.Text = RoomDB.Recordset.Fields("WEDNESDAY")
ThursdayTxt.Text = RoomDB.Recordset.Fields("THURSDAY")
FridayTxt.Text = RoomDB.Recordset.Fields("FRIDAY")
SaturdayTxt.Text = RoomDB.Recordset.Fields("SATURDAY")
SundayTxt.Text = RoomDB.Recordset.Fields("SUNDAY")
StatusTxt.Text = RoomDB.Recordset.Fields("STATUS")
TimeON.Text = RoomDB.Recordset.Fields("TIME ON")
TimeOFF.Text = RoomDB.Recordset.Fields("TIME OFF")
ONHOURS.Text = RoomDB.Recordset.Fields("ONHOURS")
ONMINUTES.Text = RoomDB.Recordset.Fields("ONMINUTES")
ONAMPM.Text = RoomDB.Recordset.Fields("ONAMPM")
OFFHOURS.Text = RoomDB.Recordset.Fields("OFFHOURS")
OFFMINUTES.Text = RoomDB.Recordset.Fields("OFFMINUTES")
OFFAMPM.Text = RoomDB.Recordset.Fields("OFFAMPM")
TimeON.Text = RoomDB.Recordset.Fields("TIME ON")
TimeOFF.Text = RoomDB.Recordset.Fields("TIME OFF")
GoSub SubDATA
ElseIf Combo1.Text = "1F HALLWAY" Then
RoomDB.RecordSource = "Select * from Config where ROOMS='" + "1F HALLWAY" +
"'"
RoomDB.Refresh
SchedulingStatus.Text = RoomDB.Recordset.Fields("SwitchSchedule")
MondayTxt.Text = RoomDB.Recordset.Fields("MONDAY")
TuesdayTxt.Text = RoomDB.Recordset.Fields("TUESDAY")
WednesdayTxt.Text = RoomDB.Recordset.Fields("WEDNESDAY")
ThursdayTxt.Text = RoomDB.Recordset.Fields("THURSDAY")
FridayTxt.Text = RoomDB.Recordset.Fields("FRIDAY")
SaturdayTxt.Text = RoomDB.Recordset.Fields("SATURDAY")
SundayTxt.Text = RoomDB.Recordset.Fields("SUNDAY")
StatusTxt.Text = RoomDB.Recordset.Fields("STATUS")
TimeON.Text = RoomDB.Recordset.Fields("TIME ON")
TimeOFF.Text = RoomDB.Recordset.Fields("TIME OFF")
ONHOURS.Text = RoomDB.Recordset.Fields("ONHOURS")
ONMINUTES.Text = RoomDB.Recordset.Fields("ONMINUTES")
ONAMPM.Text = RoomDB.Recordset.Fields("ONAMPM")
OFFHOURS.Text = RoomDB.Recordset.Fields("OFFHOURS")
OFFMINUTES.Text = RoomDB.Recordset.Fields("OFFMINUTES")
OFFAMPM.Text = RoomDB.Recordset.Fields("OFFAMPM")
TimeON.Text = RoomDB.Recordset.Fields("TIME ON")
TimeOFF.Text = RoomDB.Recordset.Fields("TIME OFF")
GoSub SubDATA
ElseIf Combo1.Text = "CLINIC" Then
RoomDB.RecordSource = "Select * from Config where ROOMS='" + "CLINIC" + "'"
RoomDB.Refresh
SchedulingStatus.Text = RoomDB.Recordset.Fields("SwitchSchedule")
MondayTxt.Text = RoomDB.Recordset.Fields("MONDAY")
TuesdayTxt.Text = RoomDB.Recordset.Fields("TUESDAY")
WednesdayTxt.Text = RoomDB.Recordset.Fields("WEDNESDAY")
164
ThursdayTxt.Text = RoomDB.Recordset.Fields("THURSDAY")
FridayTxt.Text = RoomDB.Recordset.Fields("FRIDAY")
SaturdayTxt.Text = RoomDB.Recordset.Fields("SATURDAY")
SundayTxt.Text = RoomDB.Recordset.Fields("SUNDAY")
StatusTxt.Text = RoomDB.Recordset.Fields("STATUS")
TimeON.Text = RoomDB.Recordset.Fields("TIME ON")
TimeOFF.Text = RoomDB.Recordset.Fields("TIME OFF")
ONHOURS.Text = RoomDB.Recordset.Fields("ONHOURS")
ONMINUTES.Text = RoomDB.Recordset.Fields("ONMINUTES")
ONAMPM.Text = RoomDB.Recordset.Fields("ONAMPM")
OFFHOURS.Text = RoomDB.Recordset.Fields("OFFHOURS")
OFFMINUTES.Text = RoomDB.Recordset.Fields("OFFMINUTES")
OFFAMPM.Text = RoomDB.Recordset.Fields("OFFAMPM")
TimeON.Text = RoomDB.Recordset.Fields("TIME ON")
TimeOFF.Text = RoomDB.Recordset.Fields("TIME OFF")
GoSub SubDATA
End If
Exit Sub
SubDATA:
ROOMLABEL.Caption = Combo1.Text
If SchedulingStatus.Text = "DEACTIVATED" Then
ROOMBTN.Caption = "SET SCHEDULE"
End If
If SchedulingStatus.Text = "ACTIVATED" Then
ROOMBTN.Caption = "EDIT SCHEDULE"
End If
If MondayTxt.Text = "TRUE" Then
Check1.Value = 1
End If
If MondayTxt.Text = "FALSE" Then
Check1.Value = 0
End If
If TuesdayTxt.Text = "TRUE" Then
Check2.Value = 1
End If
If TuesdayTxt.Text = "FALSE" Then
Check2.Value = 0
End If
If WednesdayTxt.Text = "TRUE" Then
Check3.Value = 1
End If
If WednesdayTxt.Text = "FALSE" Then
Check3.Value = 0
End If
If ThursdayTxt.Text = "TRUE" Then
Check4.Value = 1
End If
If ThursdayTxt.Text = "FALSE" Then
Check4.Value = 0
End If
165
ThursdayTxt.Text = RoomDB.Recordset.Fields("THURSDAY")
FridayTxt.Text = RoomDB.Recordset.Fields("FRIDAY")
SaturdayTxt.Text = RoomDB.Recordset.Fields("SATURDAY")
SundayTxt.Text = RoomDB.Recordset.Fields("SUNDAY")
StatusTxt.Text = RoomDB.Recordset.Fields("STATUS")
TimeON.Text = RoomDB.Recordset.Fields("TIME ON")
TimeOFF.Text = RoomDB.Recordset.Fields("TIME OFF")
ONHOURS.Text = RoomDB.Recordset.Fields("ONHOURS")
ONMINUTES.Text = RoomDB.Recordset.Fields("ONMINUTES")
ONAMPM.Text = RoomDB.Recordset.Fields("ONAMPM")
OFFHOURS.Text = RoomDB.Recordset.Fields("OFFHOURS")
OFFMINUTES.Text = RoomDB.Recordset.Fields("OFFMINUTES")
OFFAMPM.Text = RoomDB.Recordset.Fields("OFFAMPM")
TimeON.Text = RoomDB.Recordset.Fields("TIME ON")
TimeOFF.Text = RoomDB.Recordset.Fields("TIME OFF")
GoSub SubDATA
ElseIf Combo1.Text = "ROOM 103" Then
RoomDB.RecordSource = "Select * from Config where ROOMS='" + "103" + "'"
RoomDB.Refresh
SchedulingStatus.Text = RoomDB.Recordset.Fields("SwitchSchedule")
MondayTxt.Text = RoomDB.Recordset.Fields("MONDAY")
TuesdayTxt.Text = RoomDB.Recordset.Fields("TUESDAY")
WednesdayTxt.Text = RoomDB.Recordset.Fields("WEDNESDAY")
ThursdayTxt.Text = RoomDB.Recordset.Fields("THURSDAY")
FridayTxt.Text = RoomDB.Recordset.Fields("FRIDAY")
SaturdayTxt.Text = RoomDB.Recordset.Fields("SATURDAY")
SundayTxt.Text = RoomDB.Recordset.Fields("SUNDAY")
StatusTxt.Text = RoomDB.Recordset.Fields("STATUS")
TimeON.Text = RoomDB.Recordset.Fields("TIME ON")
TimeOFF.Text = RoomDB.Recordset.Fields("TIME OFF")
ONHOURS.Text = RoomDB.Recordset.Fields("ONHOURS")
ONMINUTES.Text = RoomDB.Recordset.Fields("ONMINUTES")
ONAMPM.Text = RoomDB.Recordset.Fields("ONAMPM")
OFFHOURS.Text = RoomDB.Recordset.Fields("OFFHOURS")
OFFMINUTES.Text = RoomDB.Recordset.Fields("OFFMINUTES")
OFFAMPM.Text = RoomDB.Recordset.Fields("OFFAMPM")
TimeON.Text = RoomDB.Recordset.Fields("TIME ON")
TimeOFF.Text = RoomDB.Recordset.Fields("TIME OFF")
GoSub SubDATA
ElseIf Combo1.Text = "ROOM 104" Then
RoomDB.RecordSource = "Select * from Config where ROOMS='" + "104" + "'"
RoomDB.Refresh
SchedulingStatus.Text = RoomDB.Recordset.Fields("SwitchSchedule")
MondayTxt.Text = RoomDB.Recordset.Fields("MONDAY")
TuesdayTxt.Text = RoomDB.Recordset.Fields("TUESDAY")
WednesdayTxt.Text = RoomDB.Recordset.Fields("WEDNESDAY")
ThursdayTxt.Text = RoomDB.Recordset.Fields("THURSDAY")
FridayTxt.Text = RoomDB.Recordset.Fields("FRIDAY")
SaturdayTxt.Text = RoomDB.Recordset.Fields("SATURDAY")
SundayTxt.Text = RoomDB.Recordset.Fields("SUNDAY")
StatusTxt.Text = RoomDB.Recordset.Fields("STATUS")
167
OFFHOURS.Text = RoomDB.Recordset.Fields("OFFHOURS")
OFFMINUTES.Text = RoomDB.Recordset.Fields("OFFMINUTES")
OFFAMPM.Text = RoomDB.Recordset.Fields("OFFAMPM")
TimeON.Text = RoomDB.Recordset.Fields("TIME ON")
TimeOFF.Text = RoomDB.Recordset.Fields("TIME OFF")
GoSub SubDATA
ElseIf Combo1.Text = "1F HALLWAY" Then
RoomDB.RecordSource = "Select * from Config where ROOMS='" + "1F HALLWAY" +
"'"
RoomDB.Refresh
SchedulingStatus.Text = RoomDB.Recordset.Fields("SwitchSchedule")
MondayTxt.Text = RoomDB.Recordset.Fields("MONDAY")
TuesdayTxt.Text = RoomDB.Recordset.Fields("TUESDAY")
WednesdayTxt.Text = RoomDB.Recordset.Fields("WEDNESDAY")
ThursdayTxt.Text = RoomDB.Recordset.Fields("THURSDAY")
FridayTxt.Text = RoomDB.Recordset.Fields("FRIDAY")
SaturdayTxt.Text = RoomDB.Recordset.Fields("SATURDAY")
SundayTxt.Text = RoomDB.Recordset.Fields("SUNDAY")
StatusTxt.Text = RoomDB.Recordset.Fields("STATUS")
TimeON.Text = RoomDB.Recordset.Fields("TIME ON")
TimeOFF.Text = RoomDB.Recordset.Fields("TIME OFF")
ONHOURS.Text = RoomDB.Recordset.Fields("ONHOURS")
ONMINUTES.Text = RoomDB.Recordset.Fields("ONMINUTES")
ONAMPM.Text = RoomDB.Recordset.Fields("ONAMPM")
OFFHOURS.Text = RoomDB.Recordset.Fields("OFFHOURS")
OFFMINUTES.Text = RoomDB.Recordset.Fields("OFFMINUTES")
OFFAMPM.Text = RoomDB.Recordset.Fields("OFFAMPM")
TimeON.Text = RoomDB.Recordset.Fields("TIME ON")
TimeOFF.Text = RoomDB.Recordset.Fields("TIME OFF")
GoSub SubDATA
ElseIf Combo1.Text = "CLINIC" Then
RoomDB.RecordSource = "Select * from Config where ROOMS='" + "CLINIC" + "'"
RoomDB.Refresh
SchedulingStatus.Text = RoomDB.Recordset.Fields("SwitchSchedule")
MondayTxt.Text = RoomDB.Recordset.Fields("MONDAY")
TuesdayTxt.Text = RoomDB.Recordset.Fields("TUESDAY")
WednesdayTxt.Text = RoomDB.Recordset.Fields("WEDNESDAY")
ThursdayTxt.Text = RoomDB.Recordset.Fields("THURSDAY")
FridayTxt.Text = RoomDB.Recordset.Fields("FRIDAY")
SaturdayTxt.Text = RoomDB.Recordset.Fields("SATURDAY")
SundayTxt.Text = RoomDB.Recordset.Fields("SUNDAY")
StatusTxt.Text = RoomDB.Recordset.Fields("STATUS")
TimeON.Text = RoomDB.Recordset.Fields("TIME ON")
TimeOFF.Text = RoomDB.Recordset.Fields("TIME OFF")
ONHOURS.Text = RoomDB.Recordset.Fields("ONHOURS")
ONMINUTES.Text = RoomDB.Recordset.Fields("ONMINUTES")
ONAMPM.Text = RoomDB.Recordset.Fields("ONAMPM")
OFFHOURS.Text = RoomDB.Recordset.Fields("OFFHOURS")
OFFMINUTES.Text = RoomDB.Recordset.Fields("OFFMINUTES")
OFFAMPM.Text = RoomDB.Recordset.Fields("OFFAMPM")
TimeON.Text = RoomDB.Recordset.Fields("TIME ON")
169
SubDATA:
ROOMLABEL.Caption = Combo1.Text
If SchedulingStatus.Text = "DEACTIVATED" Then
ROOMBTN.Caption = "SET SCHEDULE"
End If
If SchedulingStatus.Text = "ACTIVATED" Then
ROOMBTN.Caption = "EDIT SCHEDULE"
End If
If MondayTxt.Text = "TRUE" Then
Check1.Value = 1
End If
If MondayTxt.Text = "FALSE" Then
Check1.Value = 0
End If
If TuesdayTxt.Text = "TRUE" Then
Check2.Value = 1
End If
If TuesdayTxt.Text = "FALSE" Then
Check2.Value = 0
End If
If WednesdayTxt.Text = "TRUE" Then
Check3.Value = 1
End If
If WednesdayTxt.Text = "FALSE" Then
Check3.Value = 0
End If
If ThursdayTxt.Text = "TRUE" Then
Check4.Value = 1
End If
If ThursdayTxt.Text = "FALSE" Then
Check4.Value = 0
End If
If FridayTxt.Text = "TRUE" Then
Check5.Value = 1
End If
If FridayTxt.Text = "FALSE" Then
Check5.Value = 0
End If
If SaturdayTxt.Text = "TRUE" Then
Check6.Value = 1
End If
If SaturdayTxt.Text = "FALSE" Then
Check6.Value = 0
End If
If SundayTxt.Text = "TRUE" Then
Check7.Value = 1
170
End If
If SundayTxt.Text = "FALSE" Then
Check7.Value = 0
End If
End Sub
SchedulingStatus.Text = RoomDB.Recordset.Fields("SwitchSchedule")
MondayTxt.Text = RoomDB.Recordset.Fields("MONDAY")
TuesdayTxt.Text = RoomDB.Recordset.Fields("TUESDAY")
WednesdayTxt.Text = RoomDB.Recordset.Fields("WEDNESDAY")
ThursdayTxt.Text = RoomDB.Recordset.Fields("THURSDAY")
FridayTxt.Text = RoomDB.Recordset.Fields("FRIDAY")
SaturdayTxt.Text = RoomDB.Recordset.Fields("SATURDAY")
SundayTxt.Text = RoomDB.Recordset.Fields("SUNDAY")
StatusTxt.Text = RoomDB.Recordset.Fields("STATUS")
TimeON.Text = RoomDB.Recordset.Fields("TIME ON")
TimeOFF.Text = RoomDB.Recordset.Fields("TIME OFF")
ONHOURS.Text = RoomDB.Recordset.Fields("ONHOURS")
ONMINUTES.Text = RoomDB.Recordset.Fields("ONMINUTES")
ONAMPM.Text = RoomDB.Recordset.Fields("ONAMPM")
OFFHOURS.Text = RoomDB.Recordset.Fields("OFFHOURS")
OFFMINUTES.Text = RoomDB.Recordset.Fields("OFFMINUTES")
OFFAMPM.Text = RoomDB.Recordset.Fields("OFFAMPM")
TimeON.Text = RoomDB.Recordset.Fields("TIME ON")
TimeOFF.Text = RoomDB.Recordset.Fields("TIME OFF")
GoSub SubDATA
ElseIf Combo1.Text = "1F COMFORT ROOM" Then
RoomDB.RecordSource = "Select * from Config where ROOMS='" + "1F CR" + "'"
RoomDB.Refresh
SchedulingStatus.Text = RoomDB.Recordset.Fields("SwitchSchedule")
MondayTxt.Text = RoomDB.Recordset.Fields("MONDAY")
TuesdayTxt.Text = RoomDB.Recordset.Fields("TUESDAY")
WednesdayTxt.Text = RoomDB.Recordset.Fields("WEDNESDAY")
ThursdayTxt.Text = RoomDB.Recordset.Fields("THURSDAY")
FridayTxt.Text = RoomDB.Recordset.Fields("FRIDAY")
SaturdayTxt.Text = RoomDB.Recordset.Fields("SATURDAY")
SundayTxt.Text = RoomDB.Recordset.Fields("SUNDAY")
StatusTxt.Text = RoomDB.Recordset.Fields("STATUS")
TimeON.Text = RoomDB.Recordset.Fields("TIME ON")
TimeOFF.Text = RoomDB.Recordset.Fields("TIME OFF")
ONHOURS.Text = RoomDB.Recordset.Fields("ONHOURS")
ONMINUTES.Text = RoomDB.Recordset.Fields("ONMINUTES")
ONAMPM.Text = RoomDB.Recordset.Fields("ONAMPM")
OFFHOURS.Text = RoomDB.Recordset.Fields("OFFHOURS")
OFFMINUTES.Text = RoomDB.Recordset.Fields("OFFMINUTES")
OFFAMPM.Text = RoomDB.Recordset.Fields("OFFAMPM")
TimeON.Text = RoomDB.Recordset.Fields("TIME ON")
TimeOFF.Text = RoomDB.Recordset.Fields("TIME OFF")
GoSub SubDATA
ElseIf Combo1.Text = "1F HALLWAY" Then
RoomDB.RecordSource = "Select * from Config where ROOMS='" + "1F HALLWAY" +
"'"
RoomDB.Refresh
SchedulingStatus.Text = RoomDB.Recordset.Fields("SwitchSchedule")
MondayTxt.Text = RoomDB.Recordset.Fields("MONDAY")
TuesdayTxt.Text = RoomDB.Recordset.Fields("TUESDAY")
WednesdayTxt.Text = RoomDB.Recordset.Fields("WEDNESDAY")
173
ThursdayTxt.Text = RoomDB.Recordset.Fields("THURSDAY")
FridayTxt.Text = RoomDB.Recordset.Fields("FRIDAY")
SaturdayTxt.Text = RoomDB.Recordset.Fields("SATURDAY")
SundayTxt.Text = RoomDB.Recordset.Fields("SUNDAY")
StatusTxt.Text = RoomDB.Recordset.Fields("STATUS")
TimeON.Text = RoomDB.Recordset.Fields("TIME ON")
TimeOFF.Text = RoomDB.Recordset.Fields("TIME OFF")
ONHOURS.Text = RoomDB.Recordset.Fields("ONHOURS")
ONMINUTES.Text = RoomDB.Recordset.Fields("ONMINUTES")
ONAMPM.Text = RoomDB.Recordset.Fields("ONAMPM")
OFFHOURS.Text = RoomDB.Recordset.Fields("OFFHOURS")
OFFMINUTES.Text = RoomDB.Recordset.Fields("OFFMINUTES")
OFFAMPM.Text = RoomDB.Recordset.Fields("OFFAMPM")
TimeON.Text = RoomDB.Recordset.Fields("TIME ON")
TimeOFF.Text = RoomDB.Recordset.Fields("TIME OFF")
GoSub SubDATA
ElseIf Combo1.Text = "CLINIC" Then
RoomDB.RecordSource = "Select * from Config where ROOMS='" + "CLINIC" + "'"
RoomDB.Refresh
SchedulingStatus.Text = RoomDB.Recordset.Fields("SwitchSchedule")
MondayTxt.Text = RoomDB.Recordset.Fields("MONDAY")
TuesdayTxt.Text = RoomDB.Recordset.Fields("TUESDAY")
WednesdayTxt.Text = RoomDB.Recordset.Fields("WEDNESDAY")
ThursdayTxt.Text = RoomDB.Recordset.Fields("THURSDAY")
FridayTxt.Text = RoomDB.Recordset.Fields("FRIDAY")
SaturdayTxt.Text = RoomDB.Recordset.Fields("SATURDAY")
SundayTxt.Text = RoomDB.Recordset.Fields("SUNDAY")
StatusTxt.Text = RoomDB.Recordset.Fields("STATUS")
TimeON.Text = RoomDB.Recordset.Fields("TIME ON")
TimeOFF.Text = RoomDB.Recordset.Fields("TIME OFF")
ONHOURS.Text = RoomDB.Recordset.Fields("ONHOURS")
ONMINUTES.Text = RoomDB.Recordset.Fields("ONMINUTES")
ONAMPM.Text = RoomDB.Recordset.Fields("ONAMPM")
OFFHOURS.Text = RoomDB.Recordset.Fields("OFFHOURS")
OFFMINUTES.Text = RoomDB.Recordset.Fields("OFFMINUTES")
OFFAMPM.Text = RoomDB.Recordset.Fields("OFFAMPM")
TimeON.Text = RoomDB.Recordset.Fields("TIME ON")
TimeOFF.Text = RoomDB.Recordset.Fields("TIME OFF")
GoSub SubDATA
End If
Exit Sub
SubDATA:
ROOMLABEL.Caption = Combo1.Text
If SchedulingStatus.Text = "DEACTIVATED" Then
ROOMBTN.Caption = "SET SCHEDULE"
End If
If SchedulingStatus.Text = "ACTIVATED" Then
ROOMBTN.Caption = "EDIT SCHEDULE"
End If
If MondayTxt.Text = "TRUE" Then
174
Check1.Value = 1
End If
If MondayTxt.Text = "FALSE" Then
Check1.Value = 0
End If
If TuesdayTxt.Text = "TRUE" Then
Check2.Value = 1
End If
If TuesdayTxt.Text = "FALSE" Then
Check2.Value = 0
End If
If WednesdayTxt.Text = "TRUE" Then
Check3.Value = 1
End If
If WednesdayTxt.Text = "FALSE" Then
Check3.Value = 0
End If
If ThursdayTxt.Text = "TRUE" Then
Check4.Value = 1
End If
If ThursdayTxt.Text = "FALSE" Then
Check4.Value = 0
End If
If FridayTxt.Text = "TRUE" Then
Check5.Value = 1
End If
If FridayTxt.Text = "FALSE" Then
Check5.Value = 0
End If
If SaturdayTxt.Text = "TRUE" Then
Check6.Value = 1
End If
If SaturdayTxt.Text = "FALSE" Then
Check6.Value = 0
End If
If SundayTxt.Text = "TRUE" Then
Check7.Value = 1
End If
If SundayTxt.Text = "FALSE" Then
Check7.Value = 0
End If
End Sub
ThursdayTxt.Text = RoomDB.Recordset.Fields("THURSDAY")
FridayTxt.Text = RoomDB.Recordset.Fields("FRIDAY")
SaturdayTxt.Text = RoomDB.Recordset.Fields("SATURDAY")
SundayTxt.Text = RoomDB.Recordset.Fields("SUNDAY")
StatusTxt.Text = RoomDB.Recordset.Fields("STATUS")
TimeON.Text = RoomDB.Recordset.Fields("TIME ON")
TimeOFF.Text = RoomDB.Recordset.Fields("TIME OFF")
ONHOURS.Text = RoomDB.Recordset.Fields("ONHOURS")
ONMINUTES.Text = RoomDB.Recordset.Fields("ONMINUTES")
ONAMPM.Text = RoomDB.Recordset.Fields("ONAMPM")
OFFHOURS.Text = RoomDB.Recordset.Fields("OFFHOURS")
OFFMINUTES.Text = RoomDB.Recordset.Fields("OFFMINUTES")
OFFAMPM.Text = RoomDB.Recordset.Fields("OFFAMPM")
TimeON.Text = RoomDB.Recordset.Fields("TIME ON")
TimeOFF.Text = RoomDB.Recordset.Fields("TIME OFF")
GoSub SubDATA
ElseIf Combo1.Text = "ROOM 102" Then
RoomDB.RecordSource = "Select * from Config where ROOMS='" + "102" + "'"
RoomDB.Refresh
SchedulingStatus.Text = RoomDB.Recordset.Fields("SwitchSchedule")
MondayTxt.Text = RoomDB.Recordset.Fields("MONDAY")
TuesdayTxt.Text = RoomDB.Recordset.Fields("TUESDAY")
WednesdayTxt.Text = RoomDB.Recordset.Fields("WEDNESDAY")
ThursdayTxt.Text = RoomDB.Recordset.Fields("THURSDAY")
FridayTxt.Text = RoomDB.Recordset.Fields("FRIDAY")
SaturdayTxt.Text = RoomDB.Recordset.Fields("SATURDAY")
SundayTxt.Text = RoomDB.Recordset.Fields("SUNDAY")
StatusTxt.Text = RoomDB.Recordset.Fields("STATUS")
TimeON.Text = RoomDB.Recordset.Fields("TIME ON")
TimeOFF.Text = RoomDB.Recordset.Fields("TIME OFF")
ONHOURS.Text = RoomDB.Recordset.Fields("ONHOURS")
ONMINUTES.Text = RoomDB.Recordset.Fields("ONMINUTES")
ONAMPM.Text = RoomDB.Recordset.Fields("ONAMPM")
OFFHOURS.Text = RoomDB.Recordset.Fields("OFFHOURS")
OFFMINUTES.Text = RoomDB.Recordset.Fields("OFFMINUTES")
OFFAMPM.Text = RoomDB.Recordset.Fields("OFFAMPM")
TimeON.Text = RoomDB.Recordset.Fields("TIME ON")
TimeOFF.Text = RoomDB.Recordset.Fields("TIME OFF")
GoSub SubDATA
ElseIf Combo1.Text = "ROOM 103" Then
RoomDB.RecordSource = "Select * from Config where ROOMS='" + "103" + "'"
RoomDB.Refresh
SchedulingStatus.Text = RoomDB.Recordset.Fields("SwitchSchedule")
MondayTxt.Text = RoomDB.Recordset.Fields("MONDAY")
TuesdayTxt.Text = RoomDB.Recordset.Fields("TUESDAY")
WednesdayTxt.Text = RoomDB.Recordset.Fields("WEDNESDAY")
ThursdayTxt.Text = RoomDB.Recordset.Fields("THURSDAY")
FridayTxt.Text = RoomDB.Recordset.Fields("FRIDAY")
SaturdayTxt.Text = RoomDB.Recordset.Fields("SATURDAY")
SundayTxt.Text = RoomDB.Recordset.Fields("SUNDAY")
StatusTxt.Text = RoomDB.Recordset.Fields("STATUS")
176
OFFHOURS.Text = RoomDB.Recordset.Fields("OFFHOURS")
OFFMINUTES.Text = RoomDB.Recordset.Fields("OFFMINUTES")
OFFAMPM.Text = RoomDB.Recordset.Fields("OFFAMPM")
TimeON.Text = RoomDB.Recordset.Fields("TIME ON")
TimeOFF.Text = RoomDB.Recordset.Fields("TIME OFF")
GoSub SubDATA
ElseIf Combo1.Text = "1F COMFORT ROOM" Then
RoomDB.RecordSource = "Select * from Config where ROOMS='" + "1F CR" + "'"
RoomDB.Refresh
SchedulingStatus.Text = RoomDB.Recordset.Fields("SwitchSchedule")
MondayTxt.Text = RoomDB.Recordset.Fields("MONDAY")
TuesdayTxt.Text = RoomDB.Recordset.Fields("TUESDAY")
WednesdayTxt.Text = RoomDB.Recordset.Fields("WEDNESDAY")
ThursdayTxt.Text = RoomDB.Recordset.Fields("THURSDAY")
FridayTxt.Text = RoomDB.Recordset.Fields("FRIDAY")
SaturdayTxt.Text = RoomDB.Recordset.Fields("SATURDAY")
SundayTxt.Text = RoomDB.Recordset.Fields("SUNDAY")
StatusTxt.Text = RoomDB.Recordset.Fields("STATUS")
TimeON.Text = RoomDB.Recordset.Fields("TIME ON")
TimeOFF.Text = RoomDB.Recordset.Fields("TIME OFF")
ONHOURS.Text = RoomDB.Recordset.Fields("ONHOURS")
ONMINUTES.Text = RoomDB.Recordset.Fields("ONMINUTES")
ONAMPM.Text = RoomDB.Recordset.Fields("ONAMPM")
OFFHOURS.Text = RoomDB.Recordset.Fields("OFFHOURS")
OFFMINUTES.Text = RoomDB.Recordset.Fields("OFFMINUTES")
OFFAMPM.Text = RoomDB.Recordset.Fields("OFFAMPM")
TimeON.Text = RoomDB.Recordset.Fields("TIME ON")
TimeOFF.Text = RoomDB.Recordset.Fields("TIME OFF")
GoSub SubDATA
ElseIf Combo1.Text = "1F HALLWAY" Then
RoomDB.RecordSource = "Select * from Config where ROOMS='" + "1F HALLWAY" +
"'"
RoomDB.Refresh
SchedulingStatus.Text = RoomDB.Recordset.Fields("SwitchSchedule")
MondayTxt.Text = RoomDB.Recordset.Fields("MONDAY")
TuesdayTxt.Text = RoomDB.Recordset.Fields("TUESDAY")
WednesdayTxt.Text = RoomDB.Recordset.Fields("WEDNESDAY")
ThursdayTxt.Text = RoomDB.Recordset.Fields("THURSDAY")
FridayTxt.Text = RoomDB.Recordset.Fields("FRIDAY")
SaturdayTxt.Text = RoomDB.Recordset.Fields("SATURDAY")
SundayTxt.Text = RoomDB.Recordset.Fields("SUNDAY")
StatusTxt.Text = RoomDB.Recordset.Fields("STATUS")
TimeON.Text = RoomDB.Recordset.Fields("TIME ON")
TimeOFF.Text = RoomDB.Recordset.Fields("TIME OFF")
ONHOURS.Text = RoomDB.Recordset.Fields("ONHOURS")
ONMINUTES.Text = RoomDB.Recordset.Fields("ONMINUTES")
ONAMPM.Text = RoomDB.Recordset.Fields("ONAMPM")
OFFHOURS.Text = RoomDB.Recordset.Fields("OFFHOURS")
OFFMINUTES.Text = RoomDB.Recordset.Fields("OFFMINUTES")
OFFAMPM.Text = RoomDB.Recordset.Fields("OFFAMPM")
TimeON.Text = RoomDB.Recordset.Fields("TIME ON")
178
SubDATA:
ROOMLABEL.Caption = Combo1.Text
If SchedulingStatus.Text = "DEACTIVATED" Then
ROOMBTN.Caption = "SET SCHEDULE"
End If
If SchedulingStatus.Text = "ACTIVATED" Then
ROOMBTN.Caption = "EDIT SCHEDULE"
End If
If MondayTxt.Text = "TRUE" Then
Check1.Value = 1
End If
If MondayTxt.Text = "FALSE" Then
Check1.Value = 0
End If
If TuesdayTxt.Text = "TRUE" Then
Check2.Value = 1
End If
If TuesdayTxt.Text = "FALSE" Then
Check2.Value = 0
End If
If WednesdayTxt.Text = "TRUE" Then
Check3.Value = 1
End If
179
TimeONAMPM.Enabled = True
TimeOFFHOURS.Enabled = True
TimeOFFMINUTES.Enabled = True
TimeOFFAMPM.Enabled = True
End If
End If
End Sub
TimeOFFAMPM.Enabled = True
End If
End If
End Sub
End Sub
End If
End Sub
TimeOFFMINUTES.Text = OFFMINUTES.Text
TimeOFFAMPM.Text = OFFAMPM.Text
End Sub
TimeON.Text = TimeONHOURS.Text & ":" & TimeONMINUTES.Text & ":00 " &
TimeONAMPM.Text
TimeONHOURS.Text = ONHOURS.Text
TimeONMINUTES.Text = ONMINUTES.Text
TimeONAMPM.Text = ONAMPM.Text
End Sub
189
Program Output
Figure 4
Login Form
190
Figure 5
Figure 6
Figure 7
Figure 8
Figure 9
Figure 10
Figure 11
User’s Account
Figure 12
Figure 13
Device Setup
Figure 14
User’s Manual
Outline of the User’s Manual
Section 1
Introduction
System Requirements
A. Hardware Requirements
B. Software Requirements
Section 2
Getting Started
Section 3
Modes of Operation
Section 4
Advance Features
Section 5
SECTION 1
Introduction
This Appliance Wiring Control System provides user’s manual that serves
as a guideline on how to use the system in a way that user can easily understand
the system.
create a system where the students, faculty and staffs can ensure their safety in
using the Facilities of the University. Study is confined to develop a system that
uno board, the system and the data base that is made by the researchers, a
person who manage the maintenance of the university can easily control (on/off)
Access 2007 version and Arduino drivers for the connection between the System
System Requirements
The following hardware and software are needed for the effective running
of the system.
Hardware Requirements
The hardware requirements of the Appliance Wiring Control System are at least; Dual-
core processor, 2GB RAM, 512MB of video card, 80GB hard disk, monitor (at least 1366 x
The hardware’s will serve as the foundation for the system to run. And will
Software Requirements
For the Appliance Wiring Control system to work, the following software are needed;
Net framework 4.0 for Visual Basic 6.0, Arduino Software, MS Access, at least Windows XP
Operating System
that combines the relational Microsoft Jet Database Engine with graphical user
Login – Allows the User to input username and password to access the
system
SECTION 2
Getting started
To operate the Appliance Wiring Control System, the end user must follow
these following procedures
4. If the account type logged in is administrator, the user will see the
admin panel button in main menu of the system. And if it is standard
the user will see the on/off switch, switch scheduling and on/logs
button in main menu.
5. If the users want to add a user account, delete all on/off logs, setup
outputs delay, setup the connection between the system and the
hardware, and to factory data reset. The user must be a administrator
account type.
6. If the administrator users click the admin panel button on main menu
form, the user account, delete all on/off logs, setup outputs delay,
setup device connection and factory data reset button will appear.
7. If the administrator users click the users account button on admin
panel form. The user can add, edit and delete an account.
8. If the administrator users click the delete all on/off logs button on
admin panel form, confirmation message will appear if the user wants
to delete all on/off logs.
9. If the administrator users click the setup device connection button on
admin panel form. The user can setup the connection between the
system and the hardware.
10. If the administrator users click the awcs device manager button on
setup device connection form. The user will see the list of available
communication ports that can use for setup on connection.
11. If the administrator users click refresh port button, the list of the port
will automatically refresh.
12. If the administrator users click arduino com port identifier button on
awcs device manager form. The arduino com port identifier will appear
and the user will see the name of the microcontroller used in the
hardware and their exact communication port (com port).
13. If the administrator users click windows device manager button on
awcs device manager form, the windows device manager will appear.
If the user click the [+] button on the PORTS(COM & LPT) section it
199
will expand and the user will see the name of the microcontroller used
in the hardware and their exact communication port (com port).
14. If the administrator users click setup outputs delay button on admin
panel form, the user can put delay in the outputs.
15. If the administrator users click factory data reset button on admin panel
form, confirmation message will appear to start the reset.
16. If the administrator and standard users click the on/off switch button on
main menu form. the floors button will appear.
17. If the administrator and standard users click the switch button on on/off
switch form. The user can see rooms of the corresponding floor.
18. If the administrator and standard users click the room button on
corresponding floor form. The user can easily turn on or turn off the
power. If the administrator users put a delay on the outputs,
administrator and standard user will see the time of the delay in each
switch buttons.
19. If the administrator and standard users click the cancel timer button on
room form. The timer of the outputs delay will canceled.
20. If the administrator and standard users click the edit outputs label
button on room form. The user can easily change the outputs label in
each switch buttons.
21. If the administrator and standard users click the switch scheduling
button on main menu form, the user can setup a turn on and turn off
scheduling.
22. If the administrator and standard users click the on/off logs button on
main menu form, the user will see the switch operation logs.
23. If the administrator and standard users click the refresh logs button on
on/off logs form, the list of the operation logs will automatically refresh.
24. If the administrator and standard users click the sub menu button on
main menu form, sub menu will appear.
25. If the administrator and standard users click the power restore button
on sub menu form, the user can restore the power in state status.
200
26. If the administrator and standard users click the show/hide notification
bar button on sub menu form, the notification bar will show/hide.
27. If the administrator and standard users click the about awcs button on
sub menu form, the about awcs will appear.
28. If the administrator and standard users click the power restore button
on sub menu form, the user can restore the power in state status.
29. If the administrator and standard users click the log out button on sub
menu form, the log out form will appear and the confirmation message
will display.
SECTION 3
Mode of Operation
The user can operate the system through keyboard – used in the input
text, mouse – a pointing device used to click buttons to get access from the
SECTION 4
Advance Features
Appliance Wiring Control System has its own advance features and
1. The system provides safety feature because it can monitor the current
SECTION 5
Table 2
Computed mean on the acceptability of Developed Appliance Wiring Control
System In terms of Accuracy
ACCURACY Electrical Admin Electronics IT Overall
The developed system /
program…
Mean SD Mean SD Mean SD Mean SD Mean VI
1. produces accurate
results 4.71 0.47 5.00 0.00 4.50 0.52 4.70 0.48 4.68 HA
2. gives desired output 4.78 0.43 5.00 0.00 4.50 0.52 4.60 0.70 4.68 HA
3.Meets the users 4.57 0.51 5.00 0.00 4.30 0.48 4.50 0.53 4.50 HA
demand and needs
4.Provides a clear 4.71 0.47 5.00 0.00 4.50 0.66 4.90 0.51 4.65 HA
presentation
5.Providescomplete data. 4.78 0.43 4.67 0.58 4.60 0.51 4.66 0.31 4.75 HA
Average Mean 4.71 0.24 4.93 0.11 4.51 0.22 4.66 0.33 4.65 HA
The result states that item 5 “The developed system / program Provides
complete data.” got the first rank with a mean of 4.75 and a verbal interpretation
System / program gives desired output” with a mean of 4.68 and a verbal
program Meets the users demand and needs “got the last rank with a mean of
the "Electrical Experts" with an overall mean of 4.71 and a verbal interpretation of
"Highly Acceptable". followed by "IT experts" with an overall mean of 4.66 and a
The table shows that the Appliance Wiring Control System is “Highly
in terms of accuracy.
Therefore the developed system produced correct and accurate data that meets
the demands of the respective end users.
Table 3
Computed mean on the acceptability of the Developed Appliance Wiring Control
System in terms of Applicability
Applicability Electrical Admin Electronics IT Overall
The developed system /
program...
Mean SD Mean SD Mean SD Mean SD Mean VI
1. executes accordingly 4.71 0.47 4.67 0.58 4.69 0.48 4.80 0.42 4.73 HA
2. have appropriate 4.57 0.51 5.00 0.00 4.77 0.44 4.90 0.37 4.75 HA
menus
3. provides accurate and
precise information that 4.50 0.51 5.00 0.00 4.77 0.44 4.90 0.37 4.75 HA
satisfies the needs of the
user
4. is well design for the 4.79 0.43 5.00 0.00 4.92 0.28 4.70 0.48 4.82 HA
user
5. is easy to use 4.50 0.52 5.00 0.00 4.69 0.48 4.30 0.82 4.55 HA
Average Mean 4.61 0.28 4.93 0.11 4.71 0.31 4.66 0.39 4.68 HA
205
program are well design for the user”. Rank first with a overall mean of 4.83 and
4.75 and a verbal interpretation of “Highly Acceptable”. Third rank is item 1 “The
satisfies the needs of the user” and “The developed system / program are easy
to use” is in the last rank with a overall mean of 4.55 and a verbal interpretation
of “Highly Acceptable”
the "Electronics Experts" with an overall mean of 4.71 and a verbal interpretation
of "Highly Acceptable". Followed by "IT experts" with an overall mean of 4.66 and
The table shows that the Appliance Wiring Control System is “Highly
in terms of applicability.
206
Table 4
Computed mean on the acceptability of the Developed Appliance Wiring Control
System In terms of Workability
Electrical Admin Electronics IT Overall
Workability
The developed system /
program..
Mean SD Mean SD Mean SD Mean SD Mean VI
1. Operate what is it 4.93 0.27 4.67 0.58 4.85 0.38 4.80 0.42 4.85 HA
supposed to perform
2. Perform accordingly to 4.79 0.43 5.00 0.00 4.69 0.48 5.00 0.00 4.83 HA
the command
3. gives responses 4.79 0.43 4.67 0.58 4.69 0.48 4.60 0.52 4.70 HA
purposively
4. does not hang despite 4.50 0.52 5.00 0.00 4.46 0.52 4.50 0.53 4.53 HA
of invalid units
5. produce the accurate 4.71 0.47 4.67 0.58 4.85 0.38 4.60 0.52 4.73 HA
result.
Average Mean 4.74 0.25 4.80 0.35 4.71 0.19 4.70 0.30 4.73 HA
The result states that item 1 “The developed system / program operate
what it is supposed to perform”. Rank first with a overall mean of 4.85 and a
system / program produce the accurate result” with a overall mean of 4.73 and a
4.70 and a verbal interpretation of “Highly Accepted” on the fourth rank and
lastly, Item 4 “The developed system / program produce the accurate result.”
the "Electrical Experts" with an overall mean of 4.74 and a verbal interpretation of
4.71 and a verbal interpretation of "Highly Acceptable" and Lastly the "IT Experts"
The table shows that the Appliance Wiring Control System is “Highly
in terms of Workability.
Table 5
Computed mean on the acceptability of Developed Appliance Wiring Control
System In terms of Efficiency
Electrical Admin Electronics IT Overall
Efficiency
The developed system /
program Mean SD Mean SD Mean SD Mean SD Mean VI
1. is significant and 4.79 0.43 5.00 0.00 4.69 0.48 4.80 0.42 4.78 HA
useful to the user
2. performs its tasks 4.64 0.50 4.67 0.58 4.85 0.38 4.80 0.42 4.75 HA
efficiently
3. uses effective 4.86 0.36 4.67 0.58 4.69 0.48 4.80 0.42 4.78 HA
graphical user interface
4. is effective in operation 4.64 0.50 5.00 0.00 4.92 0.28 4.70 0.48 4.78 HA
as measured by time
5. are capable of 4.86 4.36 0.58 4.77 0.44 4.70 0.67 4.78 HA
4.67
producing desired result
Average Mean 4.76 0.24 4.80 0.35 4.78 0.29 4.76 0.28 4.77 HA
208
The result states that in all of the Items, item 2 “The developed system /
program performs its task efficiently” only got a overall mean of 4.75 and a verbal
interpretation of “Highly Acceptable “ and the rest of the items which is item 1
“The developed system / program is significant and useful to the user”, item 3
“The developed system / program uses graphical user interface”, item 4 “The
"Highly Acceptable". Lastly "Electrical" and "IT experts" with an overall mean of
The table shows that the Appliance Wiring Control System is “Highly
in terms of Efficiency.
And can be concluded that the developed system is easy to use for the
end user, because the instructions on how to use the system is clear and
understandable with the help of the graphical user interface. And can perform its
functions efficiently.
209
Table 6
Computed mean on the acceptability of Developed Appliance Wiring Control
System In terms of Reliability
Reliability Electrical Admin Electronics IT Overall
The developed system /
program VI
Mean SD Mean SD Mean SD Mean SD Mean
1. is modularly and can
easily be transferred in 4.50 0.52 4.33 0.58 4.77 0.44 4.90 0.32 4.68 HA
case of location transfer
2. can be placed in
strategic locations within 0.50 5.00 0.00 0.51 4.70 0.48 4.58 HA
4.36 4.62
the campus for easy
access
3. can perform 24/7 4.57 0.51 4.67 0.58 4.69 0.48 4.60 0.52 4.63 HA
5. can perform its task 4.50 0.36 4.67 0.58 4.46 0.66 4.40 0.52 4.48 HA
without overheating
Average Mean 4.47 0.36 4.67 0.42 4.61 0.39 4.68 0.26 4.59 HA
and can easily be transferred in case of location transfer” as the highest rank with
rank is the item 3 “The developed system / program can perform 24/7” with a
rank goes to items 2 “The developed system / program can be placed in strategic
locations within the campus for easy access” and item 4 “The developed system /
“The developed system / program can perform its task without overheating” as
210
the last rank with a overall mean of 4.48 and a verbal interpretation of “Highly
Acceptable”
In terms of the Respondents "IT Experts" with an overall mean of 4.68 and
the "Admin" with an overall mean of 4.67 and a verbal interpretation of "Highly
The table shows that the Appliance Wiring Control System is “Highly
in terms of Reliability.
Table 7
Composite table on the acceptability of Developed Appliance Wiring Control
System In terms of different criteria
CRITERIA Mean VI RANK
1. Accuracy 4.65 HA 4
2. Applicability 4.68 HA 3
3. Workability 4.73 HA 2
4. Efficiency 4.77 HA 1
5. Reliability 4.59 HA 5
Average Mean 4.68 HA
It resulted that “Efficiency” ranks first with the computed mean of 4.77 and
Third rank is the “Applicability” with a computed mean of 4.68 and a verbal
“Reliability” in the last rank with a computed mean of 4.59 and a verbal
The table shows that the Appliance Wiring Control System is “Highly
4.68.
The result reveals that the computed P-Value of 0.051, 0.450, 0.922,
Reliability. are greater than Alpha 0.05 level of significance thus, the null
means on the acceptability of the systems are the same for all groups.
213
Chapter 4
recommendations.
Summary of Findings
Based on the objective which is to develop and test the level acceptability
of the Appliance Wiring Control System, the following findings are hereby
summarized.
Acceptable”.
214
Conclusion
Based from the findings done, the researchers concluded that the system
BIBLIOGRAPHY
216
.
217
APPENDIX A
Gantt Chart
June July Aug. Sept. Oct. Nov. Dec. Jan. Feb. Mar.
Planning
Creating the
appropriate thesis
title
Title Defense
Gathering of Data
Development of
Chapter 1
Development of
Chapter 2
Consultation of
Adviser , Critic
Reader and
statistician
Colloquium
Revision of
manuscript
Submission of Soft
bound Copies
Development of
Chapter 3 and 4
Determining the
acceptability of the
program
Consultant to the
panel member’s
APPENDIX B
218
Dear Sir:
Greetings of peace!
Truly yours,
The Researchers
PATRICIA JOY C. CAGUIOA
KATHRINA GAILE S. ENOJADO
CHRIS JOHN E. GARRA
DANIEL E. NAVARRO III
JENNILYN E. PACHECO
CARLOS JERWIN P. SUAREZ
Noted:
Prof. RAYMOND RAMIREZ
Thesis Adviser
APPENDIX C
219
Dear Respondents,
Greetings!
You are chosen as one of the respondents who can provide pertinent information
necessary to our study, kindly accomplish the attached questionnaire checklist
supplying the needed data and rest assured that your response shall be treated with
outmost confidentiality.
Respectfully yours,
The Researchers
Noted by:
APPENDIX D
220
QUESTIONNAIRE CHECKLIST
Cainta, Rizal
Questionnaire-Checklist
Name:_______________________________________________
5 - Highly Acceptable
4 - Acceptable
3 - Moderately Acceptable
2 - Less Acceptable
1 - Not Acceptable
CRITERIA 5 4 3 2 1
1 Accuracy
221
CRITERIA 5 4 3 2 1
5 Reliability
The developed system / program…….
5.1 is modularly and can easily be transferred in case
of location transfer
5.2 can be placed in strategic locations within the
campus for easy access
5.3 can perform 24/7
5.4 wirings are properly insulated to avoid
electrocution
5.5 can perform its task without overheating
222
223
APPENDIX E
Statistical Formula
Mean:
x̅ = ∑ x
Where:
x̅ = mean
5 - Highly Acceptable
4 - Acceptable
3 - Moderately Acceptable
2 - Less Acceptable
1 - Not Acceptable
224
APPENDIX F
This College
SIR / MADAM:
In Consider of your qualification in the field of research, the College Research Council
represented by the undersigned, upon the recommendation of the Research Instructor has
approved your appointment to perform the following functions.
They shall prepare / defend their approved thesis proposal entitled DEVELOPMENT OF
APPLIANCE WIRING CONTROL SYSTEM As part of the partial fulfilment of the requirement for
the degree, BACHELOR OF SCIENCE IN INFORMATION TECHNOLOGY.
Thank you for your support and cooperation to the Research Program of the College.
Noted:
APPENDIX G
PERSONAL INFORMATION
EDUCATIONAL ATTAINMENT:
Tertiary: University of Rizal System
Gate 1 KarangalanCainta Rizal
BS Information Technology
(2014-present)
PERSONAL INFORMATION
EDUCATIONAL ATTAINMENT:
Tertiary: University of Rizal System
Gate 1 KarangalanCainta Rizal
BS Information Technology
(2014-present)
PERSONAL INFORMATION
EDUCATIONAL ATTAINMENT:
Tertiary: University of Rizal System
Gate 1 KarangalanCainta Rizal
BS Information Technology
(2013-present)
PERSONAL INFORMATION
EDUCATIONAL ATTAINMENT:
Tertiary: University of Rizal System
Gate 1 KarangalanCainta Rizal
BS Information Technology
(2014-present)
JENNILYN E. PACHECO
Address: F18 Manolotost Felix SubdBrgy San Andres Cainta, Rizal
E-mail: jenneypache@gmail.com
Contacts: +639305711285
PERSONAL INFORMATION
EDUCATIONAL ATTAINMENT:
Tertiary: University of Rizal System
Gate 1 KarangalanCainta Rizal
BS Information Technology
(2014-present)
PERSONAL INFORMATION
EDUCATIONAL ATTAINMENT:
Tertiary: University of Rizal System
Gate 1 KarangalanCainta Rizal
DT Electronics
(2012-2014)
Cainta, Rizal
(2002-2008)