Exemple #1
0
        private void pictureBox1_Click(object sender, EventArgs e)
        {
            OpenFileDialog OFD = new OpenFileDialog();

            OFD.Filter           = "All Files (*.*)|*.*";
            OFD.FilterIndex      = 1;
            OFD.Multiselect      = false;
            OFD.InitialDirectory = AppDomain.CurrentDomain.BaseDirectory + "icons";
            if (OFD.ShowDialog() == DialogResult.OK)
            {
                try
                {
                    ICON = OFD.SafeFileName;
                    pictureBox1.Image = LU.LoadImage(AppDomain.CurrentDomain.BaseDirectory + "icons\\" + ICON, 64, 64);
                }
                catch { };
            }
        }