Macro needed to read and to graph an online text file

Trinkx

New Member
Joined
Apr 7, 2023
Messages
1
Office Version
  1. 2016
Platform
  1. Windows
I need a macro to read and graph an online text file. This txt file comes from the measurements one equipment is doing. The file have 70 columns, but the number of rods is growing because the equipment will be adding a rod of data each minute.

I need to insert a new blank column C after the B column and give of it a date and hour format. Just to this point I'm able to make a macro by means of recording it.

After, I need to put a formula Cn=(An + Bn) in the 2880 last lines of column C (that corresponds to the last 2 days (24 * 60 * 2 = 2880 minutes in 2 days). The variable n will be growing as the txt file grows each time it is imported to Excel. I suppose the n value will be given to Excel as a parameter but I don't know how to do it.

Finally I need to represent in a new sheet, and XY graph with the 2880 last rows of C column as X values, and the 2880 rows of column BF as Y values.

I think this could be a good method to represent a graph for a real time txt file.

Any help will be welcome. Thanks in advance.
 

Excel Facts

Did you know Excel offers Filter by Selection?
Add the AutoFilter icon to the Quick Access Toolbar. Select a cell containing Apple, click AutoFilter, and you will get all rows with Apple
To get help you might need to provide more. I understand that there is a language issue but I do not understand what you want. Where does the text file come from? Is it CSV? What is the file name? Do you import it into a workbook? Do you want Excel to download the file from an on-line source or do you download it manually before using it? does the data always have 2880 rows or does newer data get added to the existing data?

Ideally you provide a link to the workbook and to a copy of the data file. You can do that using 1. Dropbox or 1Drive to store the file and 2. the link icon above your reply. As an alternative use Mr Excel's excellent add-in XL2BB to provide the first part of your existing workbook. Get it HERE.
 
Upvote 0

Forum statistics

Threads
1,223,228
Messages
6,170,871
Members
452,363
Latest member
merico17

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Back
Top