如何存储和检索Winforms Devexpress到MS Access数据库的RibbonGroup单选按钮和function区控件CheckBox?

在我的表单中,我使用了Ribbon控件,因为RadioGroup用于计算。 现在,我需要存储表单的内容,如果我在Gridview中单击,则需要将其检索回来。 我可以在Ribbon Control之外存储和检索textedit,查找编辑和检查。 如何从Ribbon控件中存储和检索RadioGroup?

存储CheckBox的示例我使用了此代码

bool temp = barCheckItem1.Checked; 

在Access数据库中使用“是/否”数据类型进行存储。 对于检索使用此代码

  barCheckItem1.Checked = reader.GetBoolean(2); 

这段代码适用于CheckBox,但我需要存储RadioButton RadioGroup。 如何存储和检索? 帮我。 提前致谢。

只需存储barEditItem.EditValue ,这是RadioButton的选定项。

我假设您从前一个问题中将int作为EditValue 。 所以这应该足够了。

 int selectedItem = (int)barEditItem.EditValue;//To Store 

将所选项目存储在DB中

 barEditItem.EditValue = reader.GetInt32(index);//To retrieve back