先重写RadionButton:

    }

然后就可以使用到Page里面了:
>

如何得到我们选中的那一项呢:
 lblName.Text.Trim());

                }

如果需要默认选中哪一项:
;
            }

        }

如果需要在ItemDataBound 事件中的用:DataRow dr = ((DataRowView)e.Item.DataItem).Row;,我们的Repeater 控件就只能使用项模版ItemTemplate,其他的模板最好别用。不然就会报错提示:Object reference not set to an instance of an object. 就这样的简单。需要注意的地方也说了。代码说明一切

相关文章: