patrickokeeffe Posted November 9, 2010 Share Posted November 9, 2010 The Edit Box under Controls doesn't reflect a channel or variable's current value. I find that complicates the user interface by requiring a separate variable display and some kind of labeling to distinguish actual values from last-entered-values. That's easy enough and perhaps an aware edit box could be accomplished with scripting or component messages but the Variable Value Display+Edit Box Control seems like a natural pairing - I hope it makes it into the next release. Link to comment Share on other sites More sharing options...
AzeoTech Posted November 10, 2010 Share Posted November 10, 2010 Actually, the problem with that is that if the user is editing in the box and then it changes on them, it can be really annoying. You can programmatically tell edit controls to refresh the edit boxes to whatever the set variable is currently set to using UpdateEdits(). This can either be for all the controls in a single page: page.mypage.updateEdits() or all the edit controls everywhere: page.updateEdits() Link to comment Share on other sites More sharing options...
patrickokeeffe Posted November 12, 2010 Author Share Posted November 12, 2010 I agree the user's input should take precedence while the edit control is active. If used for the wrong type of variable, it could be updating during or right after their entry which would become very annoying. I still think it would be a useful component for quasi-static values such as thresholds or set points, log file name masks and other values not controlled programmatically elsewhere. I'll have to experiment with Page.UpdateEdits() to find the most appropriate place to call it from. Thanks for pointing this function out! Link to comment Share on other sites More sharing options...
AzeoTech Posted November 13, 2010 Share Posted November 13, 2010 Please see this blog entry about the dangers of using edit controls in main hmi pages: http://www.azeotech.com/board/index.php?showtopic=3233 You also should be careful about using standard window's user interface elements in non-standard ways. It can really throw people. Link to comment Share on other sites More sharing options...
patrickokeeffe Posted November 15, 2010 Author Share Posted November 15, 2010 Thanks for the warning - that post had some excellent info and some more robust ideas than Page.UpdateEdits(). I hadn't tried adding actions to a variable display yet but I'm creating some custom variable components which look like edit boxes but bring up dialogs like my 'Set' buttons do. Link to comment Share on other sites More sharing options...
cjudson Posted November 18, 2012 Share Posted November 18, 2012 Please see this blog entry about the dangers of using edit controls in main hmi pages: http://www.azeotech....?showtopic=3233 You also should be careful about using standard window's user interface elements in non-standard ways. It can really throw people. The blog entry looks interesting but the link won't work for me. Link to comment Share on other sites More sharing options...
AzeoTech Posted November 20, 2012 Share Posted November 20, 2012 I've reenabled those forum posts. You should be able to get there now. Here's the link again: http://www.azeotech.com/board/index.php?/topic/3233-edit-boxes-in-hmi-software/ Link to comment Share on other sites More sharing options...
Recommended Posts
Archived
This topic is now archived and is closed to further replies.