<< Click to Display Table of Contents >>
EnableScaling |
The EnableScaling property enables or disables a value scale for the value sent to or received from a device. If this property is set to True, all values from the device receive scale adjustments in DeviceHigh, DeviceLow, EUHigh and EULow properties before setting it to the Value property. Otherwise, no scale adjustment is performed (reading or writing). Example:
Sub Tag_OnStartRunning()
' Adjusts the scale of temperature
' ranging from 0 to 255 at PLC, but it actually means
' 0 to 100 Celsius degrees
EU = "Celsius degrees"
EnableScaling = True
DeviceHigh = 255
DeviceLow = 0
EUHigh = 100
EULow = 0
End Sub