| | |
| | | |
| | | if (GlobalVar.dicCommunicators.ContainsKey(name)) |
| | | { |
| | | CommunicatorForm communicatorFForm = new CommunicatorForm(GlobalVar.dicCommunicators[name], name); |
| | | communicatorFForm.CommunicatorChanged += CommunicatorFForm_CommunicatorChanged; |
| | | communicatorFForm.Show(); |
| | | if (GlobalVar.dicCommunicators[name].CommunicatorBrand== CommunicatorBrand.SiemensS7) |
| | | { |
| | | CommunicatorS7Form communicatorS7Form = new CommunicatorS7Form(GlobalVar.dicCommunicators[name], name); |
| | | communicatorS7Form.CommunicatorChanged += CommunicatorS7Form_CommunicatorChanged; |
| | | communicatorS7Form.Show(); |
| | | } |
| | | else |
| | | { |
| | | CommunicatorForm communicatorFForm = new CommunicatorForm(GlobalVar.dicCommunicators[name], name); |
| | | communicatorFForm.CommunicatorChanged += CommunicatorFForm_CommunicatorChanged; |
| | | communicatorFForm.Show(); |
| | | } |
| | | } |
| | | } |
| | | } |
| | | |
| | | private void CommunicatorS7Form_CommunicatorChanged(BaseCommunicator communicator) |
| | | { |
| | | throw new NotImplementedException(); |
| | | } |
| | | |
| | | private void CommunicatorFForm_CommunicatorChanged(BaseCommunicator communicator) |
| | | { |
| | | if (this.InvokeRequired) |