
4.REFERENCING THE DATABASE USER CUSTOMIZE B-75074EN/04
- 450 -
ChangeDispDays :: Sheet1
This procedure changes the number of days for list and graph display
according to the number of the days of every month acquired with the
GetMonthDays procedure. If the number of days remains unchanged
from the previous display, however, processing is not performed.
For a list, the number of display days is changed. For a run time graph
or parts count graph, a data acquisition destination cell for each item of
the graph is set.
SetTableData :: Sheet1
This procedure sets list format data in cells. For the number of days
acquired with the GetMonthDays procedure, the For…Next statement
is repeatedly executed as a loop, and the collected data m_DispData() is
set in cells by using the Cells property. Moreover, an operation rate is
set in a cell by using the Range property.
SetChartData :: Sheet1
This procedure sets graph format data in cells. For the number of days
acquired with the GetMonthDays procedure, the For…Next statement
is repeatedly executed as a loop, and the collected data m_DispData() is
set in cells by using the Cells property. Moreover, an operation rate is
set in a cell by using the Range property.
SetCSVData :: Sheet1
This procedure displays data usable with CSV on Sheet2. In cells, list
format data is set. All cells of Sheet2 are deleted together with the
format, then the format of the cells is changed to character string. A
header portion and display items are set in cells by using the Range
property. For the number of days acquired with the GetMonthDays
procedure, the For…Next statement is repeatedly executed as a loop,
and the collected data m_DispData() is set in cells by using the Cells
property.
4.3.2.3 Timer processing procedures
With VBA, the timer control cannot be used. A pseudo timer is created
to automatically update data at certain intervals.
The OnTime method of the Application object is used to create a
pseudo timer. The OnTime method generates an event only once at
specified time. So, by calling the OnTime method again when an event
is generated, a pseudo timer function is implemented.
InitTimer :: Common
This procedure performs pseudo timer initialization. A timer event
generation interval and the name of a procedure to be executed with a
timer are acquired.
SetTimer :: Common
This procedure sets a pseudo timer. With the OnTime method, an
interval and procedure name acquired with InitTimer are set to start the
pseudo timer. Moreover, the timer start flag m_TimerFlg is set to True.