Beispiel #1
0
        private void Human_Photo_Click(object sender, EventArgs e)
        {
            صور_مكونات_جسم_الانسان op = new صور_مكونات_جسم_الانسان();

            //op.MdiParent= this;
            op.Show();
        }
Beispiel #2
0
        private void comboBox_SelectedIndexChanged(object sender, EventArgs e)
        {
            ComboBox test = (ComboBox)sender;

            if (test.Text == "Table")
            {
                TextBox t = new TextBox();
                t.Size         = new Size(50, 50);
                t.Name         = "txt1";
                t.Enabled      = true;
                t.TextChanged += new System.EventHandler(this.textBox_TextChanged);
                flowLayoutPanel3.Controls.Add(t);
                TextBox t2 = new TextBox();
                t2.Size    = new Size(50, 50);
                t2.Name    = "txt2";
                t2.Enabled = true;

                t2.TextChanged += new System.EventHandler(this.textBox2_TextChanged);
                flowLayoutPanel3.Controls.Add(t2);
                // y1 = true;
            }
            else if (test.Text == "Image")
            {
                PictureBox p = new PictureBox();

                p.Size    = new Size(100, 100);
                p.Enabled = true;
                p.Name    = "p1";
                صور_مكونات_جسم_الانسان a = new صور_مكونات_جسم_الانسان();
                a.Show();
            }
            else if (test.Text == "Number")
            {
                TextBox t6 = new TextBox();
                t6.Size    = new Size(30, 30);
                t6.Name    = "txt1";
                t6.Enabled = true;

                t7.Size        = new Size(70, 70);
                t7.Name        = "txt2";
                t7.Enabled     = true;
                t7.MouseClick += new System.Windows.Forms.MouseEventHandler(this.textBox1_MouseClick);

                t7.TextChanged += new System.EventHandler(this.textBox7_TextChanged);
                t6.TextChanged += new System.EventHandler(this.textBox6_TextChanged);
                flowLayoutPanel3.Controls.Add(t6);
                flowLayoutPanel3.Controls.Add(t7);
            }
        }
Beispiel #3
0
        public شيتات(List <string> str, string strr)
        {
            InitializeComponent();

            TextBox ttt = new TextBox();

            ttt.Text = strr;
            this.tableLayoutPanel1.Controls.Add(ttt);
            this.str = str;
            tableLayoutPanel1.BackColor = Color.DarkGray;
            for (int i = 0; i < str.Count; i++)
            {
                if (str[i] == "Date time")
                {
                    this.tableLayoutPanel1.Controls.Add(new DateTimePicker());
                }
                else if (str[i] == "Number")
                {
                    this.tableLayoutPanel1.Controls.Add(new NumericUpDown());
                }
                else if (str[i] == "Table")
                {
                    TableLayoutPanel table = new TableLayoutPanel();
                    table.RowCount    = w;
                    table.ColumnCount = z;
                    for (int p = 0; p < w; p++)
                    {
                        for (int j = 0; j < z; j++)
                        {
                            TextBox t = new TextBox();

                            table.Controls.Add(t);
                        }
                    }

                    this.tableLayoutPanel1.Controls.Add(table);
                }
                else if (str[i] == "Image")
                {
                    صور_مكونات_جسم_الانسان a = new صور_مكونات_جسم_الانسان();
                    a.Show();

                    PictureBox p = new PictureBox();
                    p.Image = Image.FromFile(str2);

                    this.tableLayoutPanel1.Controls.Add(p);
                }
                else if (str[i] == "Radio Button")
                {
                    this.tableLayoutPanel1.Controls.Add(new RadioButton());
                }
                else if (str[i] == "Text")
                {
                    this.tableLayoutPanel1.Controls.Add(new TextBox());
                }
                else if (str[i] == "Large Text")
                {
                    TextBox t = new TextBox();
                    t.Multiline = true;
                    this.tableLayoutPanel1.Controls.Add(t);
                }
                else if (str[i] == "List Box")
                {
                    this.tableLayoutPanel1.Controls.Add(new ListBox());
                }

                else if (str[i] == "Check Box")
                {
                    this.tableLayoutPanel1.Controls.Add(new CheckBox());
                }
                else if (str[i] == "Number")
                {
                    TextBox t1 = new TextBox();
                    t1.Text = z1.ToString();
                    this.tableLayoutPanel1.Controls.Add(t1);
                    TextBox t2 = new TextBox();
                    t2.Text = z2;
                    this.tableLayoutPanel1.Controls.Add(t2);
                }
                tableLayoutPanel1.RowCount++;
            }
        }