*beats head on desk*
mxAjax / CFAjax docs and other useful articles:
http://www.bifrost.com.au/blog/
2009/3/12 Priya Koya :
>
> Is this right?
>
>
>
>
~|
Adobe® ColdFusion® 8 software 8 is the most important and dramatic rel
> Ah, we are at cross wires!
Well that makes a lot more sense. That is what I get for only reading half of
the thread ...
> Anyways, I wonder if the OP has found his solution yet ;)
Wait .. there was an OP? ;-)
~|
Adobe® C
Ah, we are at cross wires! I was citing the java method as a possible
reason for the function only ever returning true (or my suspicion that
it never returns false, in response to Adrian's question) - not for it
returning a boolean (which of course it does). Perhaps pre-6 it did
sometimes return f
> >It may not be due to the java link. I found a reference that says
> ArrayAppend returned a boolean back in the days of CF >4.5. So it may
> just be a carry over.
>
> This would suggest that it *would* be to do with the java link;
> ColdFusion 4.5 was written in C++ ;)
>
No, I just meant
> Nowhere states that the function returns a boolean ;) But it is odd,
> indeed, why return anything at all. I've done it myself in functions
> and justified it with 'One day I may have some logic that returns
> false and then the calling code that is checking for the boolean wont
> break.
CF fun
All speculation (though I'm sure someone here knows the answer for sure) but:
>It may not be due to the java link. I found a reference that says ArrayAppend
>returned a boolean back in the days of CF >4.5. So it may just be a carry
>over.
This would suggest that it *would* be to do with the
> But it is odd, indeed, why return anything at all.
It depends on the class. Some use it and some do not
http://java.sun.com/j2se/1.4.2/docs/api/java/util/AbstractCollection.html#add(java.lang.Object)
> I don't believe that it ever does return false and the docs do not
> indicate that it does
> Seems like that shouldn't make sense ... a Boolean that has no 'off' state
Nowhere states that the function returns a boolean ;) But it is odd,
indeed, why return anything at all. I've done it myself in functions
and justified it with 'One day I may have some logic that returns
false and then t
Thanks for the info, Dominic. Seems like that shouldn't make sense ... a
Boolean that has no 'off' state, yet it perfectly makes sense that only an
exception could be 'false' and exceptions need to be thrown, not simply
reported as 'false'.
Thanks!
Jason
"
> Sent: Wednesday, March 11, 2009 11:25 AM
> To: "cf-talk"
> Subject: RE: Append Arrays with Structures
>
> Out of interest, I wonder what would have to happen for ArrayAppend to
> return false?!
>
> Adrian
>
>
>
>
>
@Adrian,
Interesting question ... can't really think of anything off-hand.
From: "Adrian Lynch"
Sent: Wednesday, March 11, 2009 11:25 AM
To: "cf-talk"
Subject: RE: Append Arrays with Structures
Out of interest, I wonder what
Priya Koya wrote:
> Is this right?
>
>
>
>
>
>
> for finding out he arraylen??
> because this is where it is giving me the error..
Yes, it was, Charlie just explained this again for you.
would solve the
problems you have told us about.
But just for another tact, I will also correct thi
o
> > return false?!
> >
> > Adrian
> >
> > > -Original Message-
> > > From: Dominic Watson [mailto:watson.domi...@googlemail.com]
> > > Sent: 11 March 2009 12:37
> > > To: cf-talk
> > > Subject: Re: Append Arrays with Stru
t; -Original Message-
> > From: Dominic Watson [mailto:watson.domi...@googlemail.com]
> > Sent: 11 March 2009 12:37
> > To: cf-talk
> > Subject: Re: Append Arrays with Structures
> >
> >
> > ArrayAppend does not return the array - it returns "
Out of interest, I wonder what would have to happen for ArrayAppend to
return false?!
Adrian
> -Original Message-
> From: Dominic Watson [mailto:watson.domi...@googlemail.com]
> Sent: 11 March 2009 12:37
> To: cf-talk
> Subject: Re: Append Arrays with Structures
>
>
Priya Koya wrote:
> nothing works
>
That is because the tag is not your problem.
Your problem is that in the loop, the first iteration changes your array
into a boolean. Then the second iteration throws an error because you
try to use that boolean variable as an array.
See the five p
Ian Skinner wrote:
> The first time you run that line you are overwriting your array and
> turning it into an array...
The first time you run that line you are overwriting your array and
turning it into an *boolean* ...
That would make more sense, wouldn't it.
~~
Jason,
nothing works
I tried with :
On Wed, Mar 11, 2009 at 9:16 AM, Ian Skinner wrote:
>
> Jason Fisher wrote:
> > If you're using >
>
> Or get rid of the quotes.
>
> >
>
> I.E. This also works.
>
>
>
>
~
Priya Koya wrote:
> I am getting an error here:
> *session.pageList = arrayAppend( session.pageList, structNew() )> *
>
> Error:
> Object of type class java.lang.Boolean cannot be used as an array
> On Wed, Mar 11, 2009 at 9:55 AM, Jason Fisher wrote:
As Dominic previously stated, arrayAppend()
yes, as jason pinted out, arrayappend() function differs from
listappend() - with arrayappend() one should not set the array to the
function's return:
with arrayappend:
but with listappend() one has to do:
Azadi Saryev
Sabai-dee.com
http://www.sabai-dee.com/
Priya Koya wrote:
> I am gettin
As Dominic pointed out above, just do:
ArrayAppend() returns true / false, not an array.
~|
Adobe® ColdFusion® 8 software 8 is the most important and dramatic release to
date
Get the Free Trial
http://ad.doubleclick.net/clk;
I am getting an error here:
*session.pageList = arrayAppend( session.pageList, structNew() )> *
Error:
Object of type class java.lang.Boolean cannot be used as an array
On Wed, Mar 11, 2009 at 9:55 AM, Jason Fisher wrote:
>
> You're setting the value of session.pageList to the string "arrayNew
Jason Fisher wrote:
> If you're using
Or get rid of the quotes.
>
I.E. This also works.
~|
Adobe® ColdFusion® 8 software 8 is the most important and dramatic release to
date
Get the Free Trial
http://ad.doubleclick.ne
You're setting the value of session.pageList to the string "arrayNew()", which
is throwing your error. If you're using
If this is not in a loop or something, you could just set directly:
~|
Adobe® ColdFusion® 8 software 8
ArrayAppend does not return the array - it returns "True, on
successful completion."
(http://livedocs.adobe.com/coldfusion/7/htmldocs/wwhelp/wwhimpl/common/html/wwhelp.htm?context=ColdFusion_Documentation&file=0381.htm)
So:
... etc.
Dominic
>
>
>
>
>
>
>
>
2009/3/11 Priya Koya
25 matches
Mail list logo