I have program that print labels and I have to allow user to save/remember settings for printer. So I have this code:
private void printerToolStripButton_Click(object sender, EventArgs e)
{
PrintDialog dialog = new PrintDialog();
dialog.ShowDialog();
}
User selects printer and clicks properties button, do some changes (paper size, orientation, etc.) and then click 'OK' and then click 'OK' on PrintDialog.
My problem is that those changes are not remembered... When I click button again or restart application they disappear...
Does anyone know how to persist them in application scope? Or if application scope is impossible, then maybe how to save them in the system (so when I go to control panel -> printers -> right click on printer -> preferences they will be there)?
Yu can use my own interface-driven serialization. ;)
You can extend interface-driven serialization using my xml serialization properties. By the way, interface-driven serialization is cool when you are using interface inheritance ;)