Led

Hello RobotStudio friends.

I’m new to c # so I need your help.
I have two LEDs that I want to connect to two different digital inputs.
I have tried many different variations of code but have not succeeded.

See my code below.

thanks in advance.

//
// griperOpenRob1signalBindingSource
//
this.griperOpenRob1signalBindingSource.DataSource = typeof(ABB.Robotics.DataBinding.SignalObjectCollection);
signalObject3.Name = “DI_Gripper_1_Open_R1”;
signalObject4.Name = “DI_Gripper_1_Closed_R1”;
this.griperOpenRob1signalBindingSource.Signals.Add(signalObject3);
this.griperOpenRob1signalBindingSource.Signals.Add(signalObject4);

//
// led1
//
this.led1.BorderStyle = System.Windows.Forms.BorderStyle.None;
this.led1.DataBindings.Add(new System.Windows.Forms.Binding(“Value”,this.griperOpenRob1signalBindingSource.GetListName(signalObject3), “Value”, true, System.Windows.Forms.DataSourceUpdateMode.Never));

//
// led2
//
this.led2.BorderStyle = System.Windows.Forms.BorderStyle.None;
this.led2.DataBindings.Add(new System.Windows.Forms.Binding(“Value”, this.griperOpenRob1signalBindingSource.Signals.Add(signalObject4), “Value”, true, System.Windows.Forms.DataSourceUpdateMode.Never));