Page 1 of 1

updating method called for constant value error

Posted: Fri Aug 07, 2009 12:32 pm
by ConvertFromOldNGs
by Anonymous >> Fri, 6 Feb 2004 14:58:48 GMT

hi
i've been having a some problems with the error 'updating method called for constant value'. The values i am trying to update are not constants. My programs is set up to create blanket invoices for customers. So the form has a transient proxy dictionary of proxyCustomerItems. I can create them fine and then when i try to update the price (which is an attribute that's part of the proxy class, not the actual saleItem reference) it says i'm trying to update a constant. Can you only set transient properties once? Thanks for your help.

Les

Re: updating method called for constant value error

Posted: Fri Aug 07, 2009 12:32 pm
by ConvertFromOldNGs
by allistar >> Sun, 8 Feb 2004 8:37:16 GMT

What this means is that you are doing something like this:

doSomething(anObject: MyClass);begin

anObject.setName("someString");
end;

where MyClass::setName is an "updating" method.

This would cause the "updating method called for constant value" error you see. To fix it you would do this:

doSomething(anObject: MyClass input);begin

anObject.setName("someString");
end;

Regards,
Allistar.
--
------------------------------------------------------------------
Allistar Melville
Software Developer, Analyst allistar@silvermoon.co.nz
Auckland, NEW ZEALAND

Silvermoon Software
Specialising in JADE development and consulting
Visit us at: http://www.silvermoon.co.nz
*NEW* Simple web access to Jade at: www.silvermoon.co.nz/jhp.html ------------------------------------------------------------------