Ejemplo n.º 1
0
        private void button1_Click(object sender, EventArgs e)
        {
            PrinterSetup     psd        = new PrinterSetup();
            PrinterSetupData newPrinter = new PrinterSetupData();

            if (psd.AddPrinter(newPrinter, config.printers, _getAuth()))
            {
                config.printers.Add(newPrinter);
                SaveSettings();
            }
            RefreshPrinterList();
        }
Ejemplo n.º 2
0
 private void lbPrinterList_DoubleClick(object sender, EventArgs e)
 {
     if (lbPrinterList.SelectedIndex > -1)
     {
         PrinterSetup psd = new PrinterSetup();
         psd.Controls["tbLPCname"].Enabled  = false;
         psd.Controls["tbDescript"].Enabled = false;
         if (psd.EditPrinter(config.printers[lbPrinterList.SelectedIndex], config.printers))
         {
             SaveSettings();
         }
         RefreshPrinterList();
     }
 }