PCL Tag Write Question

I am trying to write a value to a Siemens PLC through an ignition tag. The PLC Address data type is string. My Ignition tag is string. OPC Server and Item Path are mapped correctly. My simple test has a window with a label that was created from the gateway tag which shows the current value. I have a popup calendar which is set to display only time, and a button to initiate the write. Below is the button code.

date = system.date.format(event.source.parent.getComponent('Popup Test').date, "HH:mm")
print(date)
system.tag.write("[default]Asheville_ANDON/HPLRF_ANDON/System_A/Schedule/Time_Text.value",date))

When I select a time and click the button It changes the tag value and writes to the PLC location as well, but I still keep getting the following error even though it is working on all accounts.

Error writing to tag ‘[default]Asheville_ANDON/HPLRF_ANDON/System_A/Schedule/Time_Text.value’: Bad_Unsupported

Any Ideas?

Thanks in advance

Are you on Ignition 7 or 8? I tried your exact test in Ignition 7 and I did not get any error. Did you try without specifying the .value in the tag name? It works both ways for me.

Ignition 8. I got it working by doing the following.

date = str(system.date.format(event.source.parent.getComponent('Popup Test').date, "HH:mm"))
system.tag.write("[default]Asheville_ANDON/HPLRF_ANDON/System_A/Schedule/Time_Text", date)

Basically adding the “str” eliminated the error for me even though the system.date. format should already be in a string format.

Thanks for checking for me.