private void button5_Click(object sender, EventArgs e) { Identicon identicon = new Identicon(textBox1.Text.Trim(), 8); int size = Convert.ToInt32(textBox2.Text); this.Icon = identicon.GetIcon(64); }
private void button2_Click(object sender, EventArgs e) { Identicon identicon = new Identicon(textBox1.Text.Trim(), 8); int size = Convert.ToInt32(textBox2.Text); saveFileDialog.Filter = "Icon (*.ico)|*.ico"; if (saveFileDialog.ShowDialog() == DialogResult.OK) { using (FileStream fs = new FileStream(saveFileDialog.FileName, FileMode.Create)) { identicon.GetIcon(size).Save(fs); fs.Close(); fs.Dispose(); } Process.Start(saveFileDialog.FileName); } }