示例#1
0
        private void SendCanPacketsToolStripMenuItem_Click(object sender, EventArgs e)
        {
            SendPacketForm sendPacketForm = new SendPacketForm()
            {
                MdiParent = this
            };

            sendPacketForm.Show();
        }
示例#2
0
        private void Button1_Click(object sender, EventArgs e)
        {
            CanPacket currentPacket = null;

            if (canPacketGridView.CurrentRow != null)
            {
                currentPacket = (CanPacket)canPacketList[canPacketGridView.CurrentRow.Index];
            }

            if (currentPacket == null)
            {
                MessageBox.Show("Please select a CanPacket");
            }
            else
            {
                SendPacketForm sendPacketForm = new SendPacketForm(currentPacket.RawBytesString)
                {
                    MdiParent = this.MdiParent
                };
                sendPacketForm.Show();
            }
        }