Flex 表單中使用 `
// 錯誤:無論選哪個,print.selected 永遠為 false
var isPrint:Boolean = print.selected;
// 取得選中項的 label 字串
var selectedLabel:String = printGroup.selectedValue.toString();
// 轉換為布林或其他業務值
obj.isPrint = (selectedLabel == "列印") ? "true" : "false";
RadioButtonGroup 內部維護單選狀態,**只有 `selectedValue`、`selectedIndex`、`selection` (RadioButton 實例) 可靠反映當前選項**。{model.isPrint ? "列印" : "不列印"} 至 `selectedValue`。
Flex `RadioButtonGroup` 封裝了單選邏輯,**永遠使用 `selectedValue` 或 `selection` 取得選中項**,避免直接檢查子 RadioButton 的 `selected` 屬性。善用 `value` 屬性區分業務值與顯示標籤,程式碼更清晰。