Because ctr is an Integer object - not a int primitive.
Niall
- Original Message -
From: [EMAIL PROTECTED]
To: [EMAIL PROTECTED]
Sent: Thursday, February 26, 2004 5:13 PM
Subject: (Fwd) row counts in logic:iterate...
Sorry, my mailer messed up the last one, so here again
Rinke:
Your ctr seems to be an *Integer* object and you are using it as an
int. So simply say: ctr.intValue() + 1 and you should be ok.
Geeta
[EMAIL PROTECTED] wrote:
Then why do i get this error?
operator + cannot be applied to java.lang.Integer, int [javac]
out.print( ctr + 1 );
Rinke
materiari?
-Original Message-
From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED]
Sent: Thursday, February 26, 2004 11:13 AM
To: [EMAIL PROTECTED]
Subject: (Fwd) row counts in logic:iterate...
Sorry, my mailer messed up the last one, so here again...
newbie question:
I have a jsp
The + operator is an overloaded operator in Java. Here, within %= % it
thinks it is supposed to be concatenating and not adding. So, it cannot be
applied to an integer in this case because that operator is being used to
concatenate strings. I am going to assume that ctr is an integer. If
NEVER MIND. I was wrong about how %= % reads the + operator in this
case. The problem is that the value is an Integer rather than an int. I
learn something everyday.
At 10:38 AM 2/26/2004, you wrote:
The + operator is an overloaded operator in Java. Here, within %= %
it thinks it is
Sorry, my mailer messed up the last one, so here again...
newbie question:
I have a jsp which displays several rows with a logic:iterate, also
using the indexId-tag.
logic:iterate name=dateForm property=raw id=foo
indexId=ctr
I'd like to display row numbers in my table. But the
6 matches
Mail list logo