<?xml version="1.0" encoding="utf-8"?>
<feed xml:lang="en" xmlns="http://www.w3.org/2005/Atom"><title>Recent posts to Symbol for array element</title><link href="https://forge.codesys.com/forge/talk/Engineering/thread/d265a7fb6a/" rel="alternate"/><link href="https://forge.codesys.com/forge/talk/Engineering/thread/d265a7fb6a/feed.atom" rel="self"/><id>https://forge.codesys.com/forge/talk/Engineering/thread/d265a7fb6a/</id><updated>2020-02-27T14:01:06.667000Z</updated><subtitle>Recent posts to Symbol for array element</subtitle><entry><title>Symbol for array element</title><link href="https://forge.codesys.com/forge/talk/Engineering/thread/d265a7fb6a/?limit=25#3b8b" rel="alternate"/><published>2020-02-27T14:01:06.667000Z</published><updated>2020-02-27T14:01:06.667000Z</updated><author><name>krakers</name><uri>https://forge.codesys.com/u/krakers/</uri></author><id>https://forge.codesys.come57bfbd5944742e17fe92c091527ff0ba88e95dc</id><summary type="html">&lt;div class="markdown_content"&gt;&lt;p&gt;Hello all, I have an array of objects, lets say MyArray&lt;span&gt;[1..x]&lt;/span&gt; of Object.&lt;/p&gt;
&lt;p&gt;When programming I want to have a more "readable" way of addressing each object. Instead of saying MyArray&lt;span&gt;[1]&lt;/span&gt; := ...etc. I would like to say MyReadableName :=...&lt;/p&gt;
&lt;p&gt;I've looked into references, but I'm worried a bit about the whole pointer stuff. How could I do this in a good way and support online change? And where should I put the declaration and assignment of the references, it could be many many hundreds, and I don't want to clutter the Main VAR window when in online mode?&lt;/p&gt;
&lt;p&gt;Another thing I've looked at is having an enum with the readable names and using this as an index into the array. The lookup is then MyArray&lt;span&gt;[Enum.MyReadableName]&lt;/span&gt; :=... but I'm not sure if thats is a good solution. &lt;/p&gt;
&lt;p&gt;Any solutions or hints are very welcome! Thanks!&lt;/p&gt;&lt;/div&gt;</summary></entry></feed>