private void jButton1ActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_jButton1ActionPerformed
        // TODO add your handling code here:
        String print = Printing_Frame.getText();
        String color = Color_Frame.getText();
        String black = Black_Frame.getText();
        String disc = Discount_Frame.getText(); 
        if (print.length() == 0){Printing_Frame.setBackground(Color.RED);}
        else  {
            printing = Integer.parseInt(print);
            if (printing<1){Printing_Frame.setBackground(Color.RED);}
            else Printing_Frame.setBackground(Color.white);
        }
        if (color.length() == 0){Color_Frame.setBackground(Color.RED);}
        else {
            color_page = Integer.parseInt(color);
            Color_Frame.setBackground(Color.white);
        }
        if (black.length() == 0){Black_Frame.setBackground(Color.RED);}
        else{
            black_page = Integer.parseInt(black);
            Black_Frame.setBackground(Color.white);
        }
        if (disc.length() != 0) discount = Integer.parseInt(disc);
        if (((color_page!=0)||(black_page!=0))&&(printing!=0)){
            Color_Frame.setBackground(Color.white);
            Black_Frame.setBackground(Color.white);
            s=size.ChoiceSize( Size_Frame.getSelectedIndex());
            coast_p1=page.ChoicePage( Page_Frame.getSelectedIndex());
            coast_c=cover.ChoiceCover( Cover_Frame.getSelectedIndex());
            coast_l=lamination.ChoiceLamination( Lamination_Frame.getSelectedIndex());
            coast_b=binding.ChoiceBinding( Binding_Frame.getSelectedIndex());             
            thickness=page.ChoicePageT( Page_Frame.getSelectedIndex());
            density =page.ChoicePageD( Page_Frame.getSelectedIndex());        
            back = coast.ThicknessBack(color_page, black_page, thickness);
            weight =coast.Weight(color_page, black_page, s, printing, density);
            sum_color = coast.ColorPage(color_page, printing, s);
            sum_black = coast.BlackPage(black_page, printing, s);
            coast_print = coast.CoastPrint(sum_color, sum_black, printing, coast_c, s);
            coast_paper = coast.CoastPage(sum_color, sum_black, coast_p1, coast_c, printing, s);
            coast_cut = coast.CoastCut(printing);
            coast_lamination = coast.CoastLamination(s, coast_l);
            coef = coast.Coef();
            coastB = coast.CoastBook(coast_print, coast_paper, coast_cut, coast_lamination, coef, printing, coast_b,discount);
            coastT = coast.CoastPrinting(coastB, printing);
            CoastOne_Frame.setText(String.valueOf(coastB));
            CoastAll_Frame.setText(String.valueOf(coastT));
            Weight_Frame.setText(String.valueOf(weight));
            Back_Frame.setText(String.valueOf(back));
        }
    }//GEN-LAST:event_jButton1ActionPerformed