Author Topic: Message display by value in reverse  (Read 1432 times)

ronj

  • Newbie
  • *
  • Posts: 10
    • View Profile
Message display by value in reverse
« on: November 22, 2015, 11:48:05 PM »
Hi Archie,
Is there a control or some technique to allow a PLC value to be updated according to a value from a list (maybe a dropdown list)?

What I am looking for is almost the exact inverse of the "message display by value" or ideally a way to add a feature to the "message display by value" so that, in addition to the existing functionality, the message list could be used to allow the user to select a message and set the PLC to the corresponding numeric value from the list.

Regards,
Ron

bachphi

  • Hero Member
  • *****
  • Posts: 671
    • View Profile
Re: Message display by value in reverse
« Reply #1 on: November 24, 2015, 04:15:51 PM »
I would a have list box on the leftside, and list out values with description , on the rightside a basic label with PLCAddressKeypad set to PLC address you want to change its value.
===================================================
This is NOT alt.read.my.mind.
No such thing is sh^t-for-brains unless you are posting to alt.read.my.mind.
===================================================

Archie

  • Administrator
  • Hero Member
  • *****
  • Posts: 5322
    • View Profile
    • AdvancedHMI
Re: Message display by value in reverse
« Reply #2 on: November 26, 2015, 07:04:23 AM »
You could add a ListBox to the form, add the Items, then double click to get to code:

    Private Sub ListBox1_SelectedIndexChanged(sender As Object, e As EventArgs) Handles ListBox1.SelectedIndexChanged
        EthernetIPforCLXCom1.Write("ClickedItem", ListBox1.SelectedIndex)
    End Sub