<?xml version="1.0" encoding="utf-8"?>
<feed xml:lang="en" xmlns="http://www.w3.org/2005/Atom"><title>Recent posts to Time clock functioning</title><link href="https://forge.codesys.com/forge/talk/Engineering/thread/b1ca6f12bb/" rel="alternate"/><link href="https://forge.codesys.com/forge/talk/Engineering/thread/b1ca6f12bb/feed.atom" rel="self"/><id>https://forge.codesys.com/forge/talk/Engineering/thread/b1ca6f12bb/</id><updated>2021-12-17T09:57:05.751000Z</updated><subtitle>Recent posts to Time clock functioning</subtitle><entry><title>Time clock functioning</title><link href="https://forge.codesys.com/forge/talk/Engineering/thread/b1ca6f12bb/?limit=25#fc7d" rel="alternate"/><published>2021-12-17T09:57:05.751000Z</published><updated>2021-12-17T09:57:05.751000Z</updated><author><name>riccardo</name><uri>https://forge.codesys.com/u/riccardo/</uri></author><id>https://forge.codesys.combc00210075e56283625a57799b00e094a954ab7d</id><summary type="html">&lt;div class="markdown_content"&gt;&lt;p&gt;Hallo everyone,&lt;/p&gt;
&lt;p&gt;It is days I am fighting with TIME and DATE systems.&lt;br/&gt;
I'm not understanding how the system works, there are a lot of libraries and functions but no basic documents.&lt;/p&gt;
&lt;p&gt;Can some one explane me how the system works?&lt;/p&gt;
&lt;p&gt;I need to make 2 kind of work, one is a online Industrial network and in that system I need to syncrhonize the time and date with the web clock &lt;strong&gt;&lt;em&gt;(How to perform it?)&lt;/em&gt;&lt;/strong&gt; and the second one is a stand alone automation.&lt;/p&gt;
&lt;ol&gt;
&lt;li&gt;For the first one to perform what I need, in the visualization I used:&lt;/li&gt;
&lt;/ol&gt;
&lt;p&gt;%t&lt;span&gt;[hh:mm - dd/MM/yyyy]&lt;/span&gt;&lt;/p&gt;
&lt;p&gt;and this works.&lt;br/&gt;
   Successively I need create a datalog system that saves: date, time, name of the logged &lt;br/&gt;
   operator and a string that describe the event/manoeuvre/action.&lt;/p&gt;
&lt;p&gt;At this point I must capture the time and date but I don't know to which variable this code &lt;br/&gt;
   %t&lt;span&gt;[hh:mm - dd/MM/yyyy]&lt;/span&gt; refers.&lt;/p&gt;
&lt;p&gt;Exemple:&lt;br/&gt;
 IF (VisuElems.CurrentUserGroupId &amp;lt;&amp;gt; 0 AND a = 0)&lt;br/&gt;
    THEN&lt;br/&gt;
     LogArr&lt;a class="alink" href="/forge/talk-ru/1/"&gt;[1]&lt;/a&gt;.LoggedOperator := VisuElems.CurrentFullUserName;&lt;br/&gt;
     LogArr&lt;a class="alink" href="/forge/talk-ru/1/"&gt;[1]&lt;/a&gt;.AccessTime := %t&lt;span&gt;[hh:mm - dd/MM/yyyy]&lt;/span&gt;&lt;br/&gt;
    a := 1;&lt;br/&gt;
 ELSIF (a = 1 AND VisuElems.CurrentUserGroupId = 0)&lt;br/&gt;
    THEN&lt;br/&gt;
    a := 0;&lt;br/&gt;
END_IF&lt;/p&gt;
&lt;ol&gt;
&lt;li&gt;For the second one, the stand alone automation, I should use the same logger system but I &lt;br/&gt;
   don't have a WEB clock to use, It means I need to build a system to put in the right time and &lt;br/&gt;
   date and to build a fuction that count the passed time.&lt;br/&gt;
   I am sure that something like this already exists but I don't find nether the in which library &lt;br/&gt;
   nor which funtion use.&lt;/li&gt;
&lt;/ol&gt;
&lt;p&gt;Many thanks for the help.&lt;/p&gt;
&lt;p&gt;Riccardo&lt;/p&gt;&lt;/div&gt;</summary></entry></feed>