I've investigated this issue a little bit
more.
It looks like there some problems with RadioButton when
they are used in groups.
First display is generally correct, but when the display
list is refreshed, it generates some bugs.
In our case, the RadioButton group is used in a
popup, and even after the popup is deleted, some popup
display routines are still
executed.
When debugging is on, the error is generated in
RadioButton.as, at line 172, because the property group is
null :
if (_labelPlacement != "") {
value =
_labelPlacement;
} else if (_group &&
group.labelPlacement != "") { // L.172
value =
group.labelPlacement;
}
Workaround : always define labelPlacement
in all your RadioButton (so that the group labelPlacement is never
read).
I've also encountered a similar error in another case :
RadioButton groups used inside a Repeater, with the groupName defined during the
repeater execution (groupName="{theRepeater.currentIndex}").
First execution is correct, but the next ones generate
an error.
When debugging is on, the error is generated
in the RadioButton.as, at line 454, for the same reason (property
group is null) :
var g:RadioButtonGroup = group:
g.addInstance(this); //
L.454
I haven't found a workaround for this
one.
It's too bad because all of this was working in previous
beta but not on the final release ;).
Benoit Hediard
De : flexcoders@yahoogroups.com
[mailto:[EMAIL PROTECTED] De la part de Benoit
HediardEnvoyé : lundi 3 juillet 2006 12:36À :
flexcoders@yahoogroups.comObjet : [flexcoders] Flex 2 Final :
Error #1009, in RadioButton/get labelPlacement()
Error #1009: Il est
impossible d'accéder à la propriété ou la méthode d'une référence d'objet
nul.
(in english,
something like "it is not possible to access the property or the method of the
null object reference")
at
mx.controls::RadioButton/get labelPlacement()
at
mx.controls::Button/http://www.adobe.com/2006/flex/mx/internal::layoutContents()
at
mx.controls::Button/mx.controls:Button::updateDisplayList()
...
In Flex2 final, I'm
getting this error regularly...
Not tried yet to
reproduce it on a simple regular case, but it looks like pretty
random.
I don't use the
labelPlacement property in our app.
I've never
encountered this error in previous beta, only since the FP9 / Flex2
Final.
Looks like a very
annoying low level framework error, related to the layout of
RadioButtons.
Anyone else facing
this issue?
And found a
workaround?
Benoit
Hediard
__._,_.___
--
Flexcoders Mailing List
FAQ: http://groups.yahoo.com/group/flexcoders/files/flexcodersFAQ.txt
Search Archives: http://www.mail-archive.com/flexcoders%40yahoogroups.com
SPONSORED LINKS
Web site design development
Computer software development
Software design and development
Macromedia flex
Software development best practice
YAHOO! GROUPS LINKS
Visit your group "flexcoders" on the web.
To unsubscribe from this group, send an email to: [EMAIL PROTECTED]
Your use of Yahoo! Groups is subject to the Yahoo! Terms of Service.
__,_._,___