Exemple #1
0
 private void GetDialogResult(frmPegawaiLookup dialogForm)
 {
     this.nip = dialogForm._NIP;
     this.commonTextBox1.Text = dialogForm._Nama;
     this.unitkerja           = dialogForm._UnitKerja;
     this.lp      = dialogForm._LP;
     this.jabatan = dialogForm._Jabatan;
     this.alamat  = dialogForm._Alamat;
     if (this.SelectData != null)
     {
         this.SelectData(this, new EventArgs());
     }
 }
Exemple #2
0
 private void ShowDialogForm()
 {
     try
     {
         DataTable dtPegawai = new DataTable();
         using (Database db = new Database(GlobalVar.DBName))
         {
             db.Commands.Add(db.CreateCommand("usp_Lookup_Pegawai"));
             db.Commands[0].Parameters.Add(new Parameter("@str", SqlDbType.VarChar, commonTextBox1.Text));
             dtPegawai = db.Commands[0].ExecuteDataTable();
         }
         frmPegawaiLookup ifrmDialog = new frmPegawaiLookup(dtPegawai);
         ifrmDialog.ShowDialog();
         if (ifrmDialog.DialogResult == DialogResult.OK)
         {
             GetDialogResult(ifrmDialog);
         }
     }
     catch (Exception ex)
     {
         Error.LogError(ex);
     }
 }