<?xml version="1.0" encoding="utf-8"?>
<feed xml:lang="en" xmlns="http://www.w3.org/2005/Atom"><title>Recent posts to How can i read data from a file into an array?</title><link href="https://forge.codesys.com/forge/talk/CODESYS-V2/thread/e34843e51b/" rel="alternate"/><link href="https://forge.codesys.com/forge/talk/CODESYS-V2/thread/e34843e51b/feed.atom" rel="self"/><id>https://forge.codesys.com/forge/talk/CODESYS-V2/thread/e34843e51b/</id><updated>2021-08-09T08:38:05.254000Z</updated><subtitle>Recent posts to How can i read data from a file into an array?</subtitle><entry><title>How can i read data from a file into an array?</title><link href="https://forge.codesys.com/forge/talk/CODESYS-V2/thread/e34843e51b/?limit=25#dcce/6d54/00e1/ada9" rel="alternate"/><published>2021-08-09T08:38:05.254000Z</published><updated>2021-08-09T08:38:05.254000Z</updated><author><name>bogdaniovu</name><uri>https://forge.codesys.com/u/bogdaniovu/</uri></author><id>https://forge.codesys.com7b74aec9dc3a6caea0b5ef51b450d7c230acb81d</id><summary type="html">&lt;div class="markdown_content"&gt;&lt;p&gt;Sorry for the late reply.&lt;/p&gt;&lt;/div&gt;</summary></entry><entry><title>How can i read data from a file into an array?</title><link href="https://forge.codesys.com/forge/talk/CODESYS-V2/thread/e34843e51b/?limit=25#dcce/6d54/00e1/7416" rel="alternate"/><published>2021-08-09T08:38:03.960000Z</published><updated>2021-08-09T08:38:03.960000Z</updated><author><name>bogdaniovu</name><uri>https://forge.codesys.com/u/bogdaniovu/</uri></author><id>https://forge.codesys.com490dd1853bc10d200718acecf930b6fc0ec5bf9c</id><summary type="html">&lt;div class="markdown_content"&gt;&lt;p&gt;Sorry for the late reply.&lt;/p&gt;&lt;/div&gt;</summary></entry><entry><title>How can i read data from a file into an array?</title><link href="https://forge.codesys.com/forge/talk/CODESYS-V2/thread/e34843e51b/?limit=250#dcce/6d54/00e1" rel="alternate"/><published>2021-08-06T14:51:24.831000Z</published><updated>2021-08-06T14:51:24.831000Z</updated><author><name>h-hermsen</name><uri>https://forge.codesys.com/u/hermsen/</uri></author><id>https://forge.codesys.com2d7e5a0f089314557a3e90e462894e213247b1d4</id><summary type="html">&lt;div class="markdown_content"&gt;&lt;p&gt;Then you should at least post your code&lt;/p&gt;&lt;/div&gt;</summary></entry><entry><title>How can i read data from a file into an array?</title><link href="https://forge.codesys.com/forge/talk/CODESYS-V2/thread/e34843e51b/?limit=25#dcce/6d54" rel="alternate"/><published>2021-08-06T14:21:43.337000Z</published><updated>2021-08-06T14:21:43.337000Z</updated><author><name>bogdaniovu</name><uri>https://forge.codesys.com/u/bogdaniovu/</uri></author><id>https://forge.codesys.com5c236abda62abaf95c3ee016dace1ed2af541286</id><summary type="html">&lt;div class="markdown_content"&gt;&lt;p&gt;can you please be so kind and help me with the diagram or code, for the past 5 days i've been searching for a solution&lt;/p&gt;&lt;/div&gt;</summary></entry><entry><title>How can i read data from a file into an array?</title><link href="https://forge.codesys.com/forge/talk/CODESYS-V2/thread/e34843e51b/?limit=250#dcce" rel="alternate"/><published>2021-08-06T13:39:38.148000Z</published><updated>2021-08-06T13:39:38.148000Z</updated><author><name>h-hermsen</name><uri>https://forge.codesys.com/u/hermsen/</uri></author><id>https://forge.codesys.com73fcd0949f87f14082d4a0cd5aba418e0ffbc9ec</id><summary type="html">&lt;div class="markdown_content"&gt;&lt;p&gt;If you can read the file, moving string data to an array of strings shouldn't be an issue.&lt;br/&gt;
1) What does your data on file look like?&lt;br/&gt;
2) Build a struct element which can hold this re-occuring data&lt;br/&gt;
3) Read from 1 to N elements data into array of struct element&lt;span&gt;[N]&lt;/span&gt;&lt;/p&gt;&lt;/div&gt;</summary></entry><entry><title>How can i read data from a file into an array?</title><link href="https://forge.codesys.com/forge/talk/CODESYS-V2/thread/e34843e51b/?limit=25#ac80/d8b2" rel="alternate"/><published>2021-08-06T13:24:15.066000Z</published><updated>2021-08-06T13:24:15.066000Z</updated><author><name>bogdaniovu</name><uri>https://forge.codesys.com/u/bogdaniovu/</uri></author><id>https://forge.codesys.com1ffe23a7752a3dcf68bfc4945d056688805dd527</id><summary type="html">&lt;div class="markdown_content"&gt;&lt;p&gt;I'm currently solving it using Ladder, but I can also try it in FBD. I transferred the file (which contains 15 numbers) into the PLC memory using FTP, used a function to open the file and read it. Right now i'm struggling to move the numbers from the file to an array.&lt;/p&gt;&lt;/div&gt;</summary></entry><entry><title>How can i read data from a file into an array?</title><link href="https://forge.codesys.com/forge/talk/CODESYS-V2/thread/e34843e51b/?limit=25#ac80/8dbb" rel="alternate"/><published>2021-08-06T13:24:12.998000Z</published><updated>2021-08-06T13:24:12.998000Z</updated><author><name>bogdaniovu</name><uri>https://forge.codesys.com/u/bogdaniovu/</uri></author><id>https://forge.codesys.com4dbe1ee2cf0a1a03ef006ebc9cd62ece63630cb7</id><summary type="html">&lt;div class="markdown_content"&gt;&lt;p&gt;I'm currently solving it using Ladder, but I can also try it in FBD. I transferred the file (which contains 15 numbers) into the PLC memory using FTP, used a function to open the file and read it. Right now i'm struggling to move the numbers from the file to an array.&lt;/p&gt;&lt;/div&gt;</summary></entry><entry><title>How can i read data from a file into an array?</title><link href="https://forge.codesys.com/forge/talk/CODESYS-V2/thread/e34843e51b/?limit=250#ac80" rel="alternate"/><published>2021-08-06T11:06:25.994000Z</published><updated>2021-08-06T11:06:25.994000Z</updated><author><name>h-hermsen</name><uri>https://forge.codesys.com/u/hermsen/</uri></author><id>https://forge.codesys.com818716b79e426f86243ac2056007d218685f8446</id><summary type="html">&lt;div class="markdown_content"&gt;&lt;p&gt;short primer: on how to tackle this.&lt;/p&gt;
&lt;p&gt;1 choose the right language to implement the code, Structered Text is imho the most suited. FBD or CFC could also be used, but that is a matter of taste. In your case something visual like FBD or CFC is probably advised since you say you are a beginner and do not provide any previous programming experience.&lt;/p&gt;
&lt;p&gt;2 write an code (FB) that can open, close, read and write files from disk.&lt;br/&gt;
If you need examples, try to google for it or ask your OEM supplier for examples &lt;/p&gt;
&lt;p&gt;3 read a file into memory and organise it using an array.&lt;/p&gt;
&lt;p&gt;good luck&lt;/p&gt;&lt;/div&gt;</summary></entry><entry><title>How can i read data from a file into an array?</title><link href="https://forge.codesys.com/forge/talk/CODESYS-V2/thread/e34843e51b/?limit=25#c8c6" rel="alternate"/><published>2021-08-06T08:39:52.767000Z</published><updated>2021-08-06T08:39:52.767000Z</updated><author><name>bogdaniovu</name><uri>https://forge.codesys.com/u/bogdaniovu/</uri></author><id>https://forge.codesys.comb1e73f7c3fc58722962ab6675049f00fe9e49d57</id><summary type="html">&lt;div class="markdown_content"&gt;&lt;p&gt;Hi,&lt;br/&gt;
I just started learning how to program PLCs and I've been struggling with reading data from a file into an array.&lt;/p&gt;&lt;/div&gt;</summary></entry></feed>