Path: csiph.com!usenet.pasdenom.info!weretis.net!feeder4.news.weretis.net!usenet.ukfsn.org!not-for-mail From: Martin Gregorie Newsgroups: comp.lang.java.programmer Subject: Re: It doesn't see my 'if' statements Date: Tue, 26 Jun 2012 23:44:33 +0000 (UTC) Organization: UK Free Software Network Lines: 22 Message-ID: References: NNTP-Posting-Host: 84.45.235.129 Mime-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-Trace: localhost.localdomain 1340754273 27134 84.45.235.129 (26 Jun 2012 23:44:33 GMT) X-Complaints-To: usenet@localhost.localdomain NNTP-Posting-Date: Tue, 26 Jun 2012 23:44:33 +0000 (UTC) User-Agent: Pan/0.135 (Tomorrow I'll Wake Up and Scald Myself with Tea; GIT 30dc37b master) Xref: csiph.com comp.lang.java.programmer:15631 On Tue, 26 Jun 2012 15:52:41 -0700, markspace wrote: > On 6/26/2012 3:49 PM, bilsch wrote: > >> public void actionPerformed(ActionEvent event){ >> String btn = event.getActionCommand(); >> // opflag clears display if (opFlag = true){ > > > This is assignment, not == test. You need two == for equals testing. > > If you are using NetBeans, it should have flagged this with a warning. > Mine does. As far as I can see the result of your calculation is never written to gui.number1 -- martin@ | Martin Gregorie gregorie. | Essex, UK org |