Ejemplo n.º 1
0
 private void button1_Click(object sender, EventArgs e)
 {
     res               = new ME2BioConversation.EntryListReplyListStruct();
     res.Paraphrase    = textBox1.Text;
     res.refParaphrase = Int32.Parse(textBox2.Text);
     res.CategoryValue = pcc.FindNameOrAdd(comboBox1.Text);
     res.Index         = Int32.Parse(textBox4.Text);
     state             = 1;
 }
        public int WriteNameProperty(MemoryStream m, string name, NameReference nameRef)
        {
            int NAME_name = FindName(name);
            int NAME_type = FindName("NameProperty");

            m.Write(BitConverter.GetBytes(NAME_name), 0, 4);
            m.Write(BitConverter.GetBytes(0), 0, 4);
            m.Write(BitConverter.GetBytes(NAME_type), 0, 4);
            m.Write(BitConverter.GetBytes(0), 0, 4);
            m.Write(BitConverter.GetBytes(4), 0, 4);
            m.Write(BitConverter.GetBytes(0), 0, 4);
            m.Write(BitConverter.GetBytes(pcc.FindNameOrAdd(nameRef.Name)), 0, 4);
            m.Write(BitConverter.GetBytes(nameRef.Number), 0, 4);
            return(32);
        }