예제 #1
0
        private void btnGo_Click(object sender, EventArgs e)
        {
            int StructureNumber;
            try
            {
                StructureNumber = this.numStructure.IntValue;
            }
            catch(FormatException )
            {
                return;
            }

            StructureObj structure = Store.Structures.GetObjectByID((long)StructureNumber);
            if (structure == null)
            {
                MessageBox.Show(this, "No structure found with that ID", "Error", MessageBoxButtons.OK);
                return;
            }

            Structure structView = new Structure(structure);

            structView.ShowProperties();

            this.Close();
        }