Jump to content

MI Value in Data Table


Recommended Posts

Hi Mr (Mrs)

Is possible i change (or replace) the format off values from a MI writed in a data table (data table example in attach) ?

I have values starting in 0 until 990. In the data tables the values are writing (O, 10, 20,...100,....990). I need store in data table the values in format as like in display. On display is possible change the format (base format, leading zeroes) for show the values (001, 010,...020,...100,..110,...990).

Is possible use this format (010, 020, 030...) in data table ?

Thanks for your´s attention.

post-1695-010417400 1314748908_thumb.jpg

post-1695-090963400 1314748915_thumb.jpg

Link to comment
Share on other sites

  • MVP 2014

The only way I can see to do this would be to convert the number to an ASCII string and set those properties in the string conversion. Then save the value to the DT as a string instead of an MI.

I guess the underlying question is: Why do you want to display the number in the DT with leading zeros? Usually that format is used to make a neat HMI screen or to simplify ASCII communications (for example with data from digital scales or barcode readers).

Link to comment
Share on other sites

The only way I can see to do this would be to convert the number to an ASCII string and set those properties in the string conversion. Then save the value to the DT as a string instead of an MI.

I guess the underlying question is: Why do you want to display the number in the DT with leading zeros? Usually that format is used to make a neat HMI screen or to simplify ASCII communications (for example with data from digital scales or barcode readers).

Mr Simon

I need show zeros because the plc show values equal displayed in water meter´s (analogic display in device).

Was possible leading zeros as you suggest :-)

Many Thanks

Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...

Important Information

This site uses cookies. By clicking I accept, you agree to their use.