예제 #1
0
 private void button4_Click(object sender, EventArgs e)
 {
     try
     {
         Part part = new Part(clientParams[0], clientParams[1]);
         if (clientParams[5] == "")
         {
             clientParams[5] = "0";  //Abit hardcoded, means that if no data for necessary, default 0 is given. (necessary is bot fixed because no models use that specific part yet)
         }
         var form = new OrderPartForm(part, Convert.ToInt32(clientParams[5]) - (Convert.ToInt32(clientParams[3]) + Convert.ToInt32(clientParams[4])));
         form.Location      = this.Location;
         form.StartPosition = FormStartPosition.Manual;
         form.FormClosing  += delegate { this.Show(); UpdatePartsTable(); InternalApp.SetRequiredPartsList(); };
         form.Show();
     }
     catch
     {
         partInfo = "Please select an item";
     }
 }