Help on exporting Citect SCADA reports to Excel

Mehak

Member
Join Date
Jul 2021
Location
Lahore
Posts
6
Hello Everyone,

I am working on reports in Vijeo Citect V7.40. I want to generate a report whenever I press the button. I am able to generate it according to date like making a Cicode file and adding the form, whenever I press the button form will open to give me the option to select the date. Similarly, I am trying to make a form for a time also. Can someone guide me on how to do this?

STRING sdate,edate,Em,D,M,Y;

D = DateDay(TimeCurrent());
M = DateMonth(TimeCurrent());
Y = DateYear(TimeCurrent(),1);

sdate= "Start Date";
edate= "End Date";
INT hChannel_M;

FormNew("Select Report date..",38,2,16);
FormInput(20,0,"DD-MM-YYYY Format",Em,20);


D = DateDay(TimeCurrent());
M = DateMonth(TimeCurrent());
Y = DateYear(TimeCurrent(),1);

FormComboBox(2 ,0, 15, 6, sDate, 1);
FormAddList(D + "-" + M + "-" + Y);
FormButton(8 ,1 ,"Select",0, 1);
FormButton(16 ,1 ,"Cancel",0, 2);

FormRead(0);

STRING START_DATE_TIME
D = DateDay(StrToDate(sdate)); //DateAdd Will convert only when the date is in System Date Format
M = DateMonth(StrToDate(sdate));
Y = DateYear(StrToDate(sdate),1);
START_DATE_TIME = Y + "-" + M + "-" + D;

STRING END_DATE_TIME
D = DateDay(DateAdd(StrToDate(sdate),86400)); //DateAdd Will convert only when the date is in System Date Format
M = DateMonth(DateAdd(StrToDate(sdate),86400));
Y = DateYear(DateAdd(StrToDate(sdate),86400),1);

END_DATE_TIME = Y + "-" + M + "-" + D;

VbCallRun(VbCallOpen("GetRep", START_DATE_TIME, END_DATE_TIME));
This is my code for date selection.
 

Similar Topics

We are currently in the testing phase with our Tag based driver for CLX PLCs. One of our reps is testing it with a Control Logix that has a...
Replies
4
Views
5,006
I've adjusted the IP of the Panelview Plus as well as the DNS servers; the screen does not show up in the search when I go to the transfer utility...
Replies
3
Views
101
Hi Everyone, I own a GE Versamax controller that I purchased for a class at Long Beach City College a couple of years ago. I lost the use of my...
Replies
7
Views
126
I was wondering if anyone could help i am trying to use a SLC 500 with a 5/05 processor to set up an incremental encoder to a HSCE2 card? The card...
Replies
2
Views
159
Hello, I am working with cimplicity workbench, I have made changes to the current project from this machine I am using in the past. However when...
Replies
0
Views
49
Back
Top Bottom