Historical Logging files produced are "generic"

I am attempting to create a custom log file which will log a specific event which throws an error.

Ideally I would like to capture the error line displayed to the console, picture below. (relevant part is highlighted in yellow)

From talking to customer support, this is not possible - so that leads me to my next point.

I am capturing a historical log, using the snippet of code shown below.
historical_logging

My problem arises when I go to view the log file, and it is “generic”.
The files contains the following line:
“TagId”;“TimeInt”;“TimeStr”;“IsInitValue”;“Value”;“IQuality”

I am assuming there is a way to get those values to contain real information rather than placeholder variables. I also tried to use an event log export block descriptor rather than historical log, and the file contained the following line:
“EventTimeInt”;“EventTimeStr”;“EventStr”;“ThreadStr”;“ThreadId”;“Event”

So essentially the same issue, with a different set of variables.

How do I get these variables to populate with “real” information?

Thank you in advance!

Hello,

Are you able to supply a backup of the device with support files? I would like to review the whole code and tag settings.

Revieing the code, you can possible do an ONERROR trigger and set it to record the string.

However, I would like to review your code as is, so that I may have thorough understanding of the task at hand.

Here is a backup as requested.

MOVED TO STAFF NOTE (223 KB)

Hello again,

I am currently using the on ONERROR trigger to capture my errors, but am still looking for a solution to record the string.

Have you had a chance to look through the code?

Thanks in advance,

Dan

Hey Kevin,

I sent you the requested backup 9 days ago and have yet to hear back - have you had a chance to review the code?

hello,

yes i have reviewed the code. I even tried to simulate the code itself on my device. I received the code error as well.

i am little confused on the purpose of this script. Are you trying to isolate the errors during the script or errors in the event logs?

The errors that are found in the compilation process are only displayed in the compiler, unless additional code is set up to send it to the event logs. It can give the error, and you can user our programming IDE document to filter the error types, but the summary may not be transferred over as well.

So I suppose my best approach would be to save the summaries are strings, and write those when a certain error code appears.

Topic closed due to inactivity.