我需要一些帮助来获取整数,然后在我从用户添加的内容中获取整数后,我需要向它添加 10,感谢帮助,代码如下;\
private void btnCalculateMouseClicked(java.awt.event.MouseEvent evt)
{
Integer memoryAdd1, total, radBlue1, radWhite1, radBlack1, microsoftYes1,
caseA1, batteryA1, webcamA1, windows20001, windowsVista1;
radBlack1 = 0;
radWhite1 = 0;
radBlue1 = 0;
microsoftYes1 = 0;
caseA1 = 0;
batteryA1 = 0;
webcamA1 = 0;
windows20001 = 0;
windowsVista1 = 0;
memoryAdd1 = 0;
if (radBlack.isSelected()) { radBlack1 = radBlack1 + 5; };
if (radWhite.isSelected()) { radWhite1 = radWhite1 + 5; };
if (radBlue.isSelected()) { radWhite1 = radWhite1 + 10; };
memoryAdd.getText(Integer.toString( memoryAdd1 = memoryAdd1+10));
if (microsoftYes.isSelected()) { microsoftYes1 = microsoftYes1 + 100; };
if (caseA.isSelected()) { caseA1 = caseA1 + 50; };
if (batteryA.isSelected()) { batteryA1 = batteryA1 + 30; };
if (webcamA.isSelected()) { webcamA1 = webcamA1 + 25; };
if (windows2000.isSelected()) { windows20001 = windows20001 + 300; };
if (windowsVista.isSelected()) { windowsVista1 = windowsVista1 + 300; };
total = radBlack1 + radWhite1 + radBlue1 + microsoftYes1 + caseA1 +
batteryA1 + webcamA1 + windows20001 + windowsVista1;
beforeTax.setText(Integer.toString(total));
}