示例#1
0
        string fileName = string.Empty; //宣告一個存取拖曳檔案的路徑


        private void FrmMyAlbum_Load(object sender, EventArgs e)
        {
            MyAlbumEntities3 ae3 = new MyAlbumEntities3();
            var alQuery          = from al in ae3.Photos
                                   select al.Description;

            foreach (string com in alQuery)
            {
                comboBox1.Text = com;
            }
            相片管理 f = new 相片管理();

            f.TopLevel        = false;
            f.Dock            = DockStyle.Fill;
            f.FormBorderStyle = FormBorderStyle.None;

            f.Show();

            panel1.Controls.Clear();
            panel1.Controls.Add(f);
            //允許pictureBox1接受拖曳檔案
            flowLayoutPanel2.AllowDrop = true;
        }
示例#2
0
        private void label1_Click(object sender, EventArgs e)
        {
            相片管理 相片 = new 相片管理();

            相片.Show();
        }