FTView VBA Help

HCSDoug

Member
Join Date
Aug 2013
Location
Here
Posts
6
In the past i have used Citect SCADA software, more specifically cicode, to log values to an excel spread sheet daily at midnight from an event.

is it possible to create VBA on a numeric input change to do the same?

I am not well versed in VBA and any help would be greatly appreciated.

Here is the Cicode that i have used in the past...

// Start of Function "Logfiles"
//
// This function saves information to the C:/Logfiles
// each day.
FUNCTION Logfiles()

FileName = "FLOW" + IntToStr(DateMonth(TimeCurrent())) + IntToStr(DateYear(TimeCurrent(),1));
MonthFile = "C:\LOGFILES\" + FileName + ".CSV";

IF FileExist(MonthFile) = 0 THEN
FileCode=FileOpen(MonthFile,"a");
FileString = "Date,Time,EFFLUENT DAILY FLOW, RUNNING FLOW TOTAL";
FileErr = FileWriteLn(FileCode, FileString);
FileClose(FileCode);
Sleep(1);
END;
FileCode=FileOpen(MonthFile,"a");
FileString = Date() +","+Time()+","+RealToStr(EFF_FLOW_ACC_Daily/1,5,3)
+","+RealToStr(EFF_FLOW_ACC/1,5,3);

FileErr = FileWriteLn(FileCode, FileString);
FileClose(FileCode)
 

Similar Topics

I've been working on a fairly large project for the last couple months and have come to a road block for the last week. I've spent countless...
Replies
7
Views
7,101
Dear Forum users i have a project, which i have to creat 2 recipe form with about 20 parameters in VBA form. - 1 recipe form used to fill...
Replies
0
Views
4,174
I am using FTView SE 5.10 I am trying to access the value of a string display on a graphic from VBA code but cannot get it to work. Something...
Replies
2
Views
5,623
Hi all. Currently I'm working on a VBa script for FTView. I would like to understand a bit better about some commands. 1) What are the...
Replies
3
Views
595
Hi all. I'm running a VBA code on my FTView which is actually working, but everytime I open the display that calls the VBA code, it throws the...
Replies
28
Views
1,801
Back
Top Bottom