Pokaż
Ignoruj:
Data:
2009-04-03 09:04:39 (17 years ago)
Autor:
marek
Opis:

re #150

Pliki:
1 zmodyfikowane

Legenda:

Bez zmian
Dodane
Usunięte
  • trunk/BazaReklam/ClientsForm.cs

    r517 r526  
    990990        private void dodajToolStripButton_Click(object sender, EventArgs e) 
    991991        { 
    992             ////AddClient addClient = new AddClient(73326); 
    993             //AddClient addClient = new AddClient(); 
     992            //AddClient addClient = new AddClient(kLIENCIBindingSource); 
    994993            //addClient.ShowDialog(); 
    995994            //return; 
     
    23602359        private void dodajTytulButton_Click(object sender, EventArgs e) 
    23612360        { 
    2362             if (kLIENCIBindingSource.Current == null) 
    2363             { 
    2364                 return; 
    2365             } 
     2361            if (kLIENCIBindingSource.Current == null) return; 
    23662362 
    23672363            if (tytulyListBox.SelectedValue == null) 
     
    25772573            if (kLIENCIBindingSource.Current == null) return; 
    25782574 
    2579             DataRowView row = (DataRowView)kLIENCIBindingSource.Current; 
    2580             REKLAMADataSet.KLIENCIRow klient = (REKLAMADataSet.KLIENCIRow)row.Row; 
    2581  
    2582             AddClient addClient = new AddClient(klient.CustomerID); 
    2583             addClient.ShowDialog(); 
     2575            DataRowView row = (DataRowView) kLIENCIBindingSource.Current; 
     2576            REKLAMADataSet.KLIENCIRow klient = (REKLAMADataSet.KLIENCIRow) row.Row; 
     2577 
     2578            AddClient addClient = new AddClient(klient.CustomerID, kLIENCIBindingSource); 
     2579            DialogResult dialogResult = addClient.ShowDialog(); 
     2580            if (dialogResult == DialogResult.OK) 
     2581            { 
     2582                pokazKlienta(klient.CustomerID); 
     2583            } 
     2584                 
     2585        } 
     2586 
     2587        private void clientsDataGridView_CellDoubleClick(object sender, DataGridViewCellEventArgs e) 
     2588        { 
     2589            //if (kLIENCIBindingSource.Current == null) return; 
     2590 
     2591            //DataRowView row = (DataRowView)kLIENCIBindingSource.Current; 
     2592            //REKLAMADataSet.KLIENCIRow klient = (REKLAMADataSet.KLIENCIRow)row.Row; 
     2593 
     2594            //AddClient addClient = new AddClient(klient.CustomerID); 
     2595            //DialogResult dialogResult = addClient.ShowDialog(); 
     2596            //if (dialogResult == DialogResult.OK) 
     2597            //{ 
     2598            //    pokazKlienta(klient.CustomerID); 
     2599            //} 
    25842600        } 
    25852601    }