Friends today, I will tell you how to create a report.
Or how to feed your realtime data or your graph data to your Excel file.
For that purpose.
I just go to my diagram window over here.
Just right click.
You have to install report generation toolkit to do your live view or here.
As you see, I have different tool or you can say different nodes related to report generation.
Like over here I have my office report.
What specific?
Excel specific.
So today I will tell you Excel specific.
So for that purpose, first you have to create report.
I just locate, create report.
Then you have to.
Go to first.
Your loop because I want to.
Data or feed data many times as many as my loop runs.
So I just use why loop over here?
So.
You have to now go to your Excel specific over here.
You have to use Excel set cell alignment.
That is an Excel set cell alignment that is in Excel format.
Just drag and drop this.
Okay.
Just connect this.
Or here you have to set the format.
Which type of report you want.
So I just create a constant over here.
Over here we have three.
Types.
XHTML.
Word Excel.
Right now I'm working with Excel, so my report type is Excel over here.
Now I just go back to my report Generation Toolkit, or here I want to use append table to report.
Append able to report, as you see, just drag and drop.
Connect this.
This will take data from other variables like you have temperature, you have pressure, you have flow,
you have current, you have voltage, etc. It will feed it to this part.
And over here in the.
Excel set sail alignment.
We have different formats.
So over here, I just.
Create content over here.
Create constant over here.
So when you go to your help, as you see horizontal alignment, vertical alignment.
So in this case, I just put, let's say center.
So my horizontal and vertical, both the alignments are center specific.
So now I just go to.
Attend, able to report or here you have different formats.
So first.
I just create.
Constant.
For this one.
For Colon because I just want a table in which first we have serial number.
In the second, we have temperature data.
In the third, we have pressure data.
In the fourth, we have floated.
So let's say.
Just.
Drag this.
So I just increase the size.
So first one is my.
Serial number.
Okay.
Second one is my temperature.
It is my pleasure.
And fourth is my flow.
Let's see.
Okay, so this is the heading.
Now you have to go to the next part in this.
You have to save your report.
So to save your report, you just go to advance.
Or here you have a report option which will use.
Clear report.
Which is used outside and you have to save report to file also.
So save report.
This one.
You have to drag.
So I just move it over here.
Just connect this.
It will save your report.
And if you want to dispose your file, you can also do that using.
Dispose.
This one using this function.
It will dispose your report also.
So this is.
These are the four or you can say one, two, three or five.
These five are the main building block of every generation.
So I just also create the labels for this.
Visible items labels OC.
So over here, as you see, labels are also visible.
Now I want to feed the data to this append table.
For that purpose, I just create data.
So first, let's say I have random numbers.
I just use this random number.
You can use this also.
It will generate 0 to 1 and it will generate according to your limits.
So I just use this one.
And over here I just make it clothing type.
So upper limit for my temperature is, let's say, 60 degrees Celsius.
And the lower limit for my temperature is, let's say ten degrees Celsius in my location.
It is not going below ten degrees Celsius.
Right now I'm creating a demo.
So now you have to convert this data into stream because right now it is in DB.
So format into string we just use.
In the strings.
Format into string.
Okay, so I just drag and drop.
Connect this.
Because this will generate the data.
And if you are dealing with real time data, you have to connect this.
Or you can replace this one with your real time data.
Like you can use data assistant and in the next video.
I will continue with that also.
So now this is my, let's say, temperature data.
Then you have to also format this string.
So you have to select how many decimals you require in this case.
So the format is percentage got to F and if you want to check or here in the detail help, you can get
the data also.
Which format is used.
So over here, just drag and.
Like over here.
This is the format you can use.
That is interesting.
Then
just.
I just closed this because I need.
Three types of data.
So I just drag and drop over here and my pressure data will go from zero to, let's say, under Pascal.
And my low data.
Is again, let's say 0 to 100.
So again, you have to use formatting to string.
Just connect this.
And the format is again same.
Now you have to create, build, add a function.
Because we want to combine all these data.
Listing.
So I just use four.
So first one is my serial number that will come from my iteration.
That will come when you come from my creation.
It is not connected directly because I need again formatting to string for this also.
The format.
So we're here right now.
The data is converted into string.
This is my serial number.
This is my temperature data over here.
This is my.
Sure, Rita.
And this is my Florida.
Now, I want to just.
Insert into an array.
This data I want to insert into an array.
For that purpose, I just.
Go to array insert into an array.
Just connect this.
Okay.
And now you have to.
Connect to the edge of.
Your value replace with shift registers.
Now.
The data will go from.
One place to another place means when first time loop runs, it will get the data again.
When a second time loop runs, it will store the data over here and third time it will.
And then it will store data one by one.
So in the case of separators over here, we have the initial data.
So I just create constant.
And right now I have two data.
So you trace this and this data that.
Is generated by inserting into string.
It will go to the append file.
So over here, this is a row header.
In this case I need not require any header and I just connect this data over here.
Control you.
Minimize it.
So right now, the program is ready and I just put some delay inside this.
Let's see.
Create constant 500 milliseconds after.
500 milliseconds data will feed it to our system.
So right now I also create file.
But also so over here, create a control over here.
It will give me the file path.
And right now Broken Arrow is there because my loop is not connected.
Gusto button when I have to stop this.
So it is now the program is ready.
So I just check it is working or not.
Or.
So over here.
And to drag this over here, you have to.
Just read your file.
Or just feed your Excel file.
So I just.
Create an Excel file over here.
You have to just give the path.
So over here is my data.
And I just need to set the pot over here.
So just open it.
Desktop and the data Excel file is there.
Click okay.
So when I hit don't run button.
Data is filtered through my Excel file and it will.
Automatically open my Excel sheet.
As you see, I just close this as you see serial number temperature pressure and it is horizontally
centered and vertically centered.
So it will generate the data.
So as you see.
If you see this is automatically generated in the case of your real time data if you want to.
Slate or.
If you want to change anything inside it, you can do it in the front, not front panel in the block
diagram.
So this is how my program works.
So let's say I want to stop the program.
When I stopped the program.
It will also dispose my Excel sheet over here.
Let's check data stored in the file.
This one when I again hit on run button.
It will disclose this data.
No data is fitted to my Excel files right now.
93.
Total 93 times my loop runs.
Let's check again.
When I hit on a run button.
And I again you don't run button.
As you see.
I just closed this.
Let's close this.
So now I want to again hit on Ron button.
Total 93 data is fitted to my Excel sheet.
Let's check.
So right now I just want to stop over here.
And let's check how much data is there inside the Excel sheet.
Every time you need another report, you have to just change the file.
But right now, only 24 times my luguentz not 24 total 22.
Because over here is my iteration from 0 to 22 means total 23 times my loop runs.
So this is all about how you can generate a report using leg view and using report generation tool.
Thank you.