Sign in to follow this  
Followers 0
Simon27

Problem Using data block on NS5

5 posts in this topic

Hi there, I wish to use data block features with NS5 and CJ1M on an application. Everything works fine. However, i still have a problem : I have two screens : - a technician screen where you can add new entries, delete, modify, etc. (with password) - a production screen with read only capabilities, which is used to select a product and transfer its parameters to a PLC My problem is that on this second screen, I can still edit the label of the entry, which I want to avoid. If I disable the input on the control flag page, I cannot select nor transfer from the table anymore... Is there another way to obtain this functionality ? Thanks for your help.

Share this post


Link to post
Share on other sites
I have done something similar on a NS8 screen... Set the 'Record Label' column width to zero, and have an extra text field in your data block that you use to label the record with instead. (This also means that the record name you select can be stored in the PLC, which may or may not be useful to you.) Next, have a macro running in 'Before Inputting Numeral/String'. I have used this code: 'Job Name modification prohibited if $B2 equal to 0. 'RETURN(1) means exit macro and abort object operation. IF ($B2 == 0) RETURN(1) ENDIF; This simply stops editing of any fields and aborts the operation if $B2 is set to zero. ($B2 is nothing special, just a system bit I picked to use. Setting $B2 to a value other than zero will allow edits to be made to the fields. Hope that helps. Andy.

Share this post


Link to post
Share on other sites
another possibility is to put a transparent button on top of the labels and make it inactive through the control flag ( no macro necessary) I do this all the time Beegee

Share this post


Link to post
Share on other sites
Thanks a lot for your help. Il have used Andy's solution and it works perfectly. Simon

Share this post


Link to post
Share on other sites
Glad it worked for you. I must admit though, Data Blocks seem a bit cumbersome to work with. Andy.

Share this post


Link to post
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
Sign in to follow this  
Followers 0