hi,
i have a DB that contains some tables.so i have a radio button group of tow radio button to display a field.
now how can i bind this radio button group to this field for updating and insert a new record?
for more explain i brought a little of code below:
in .aspx page i have:
<asp:RadioButton ID="admin" runat="server" Checked="True" GroupName="membertype" Text="admin" OnCheckedChanged="admin_CheckedChanged" /><br /> <asp:RadioButton ID="member" runat="server" GroupName="membertype" Text="member" />
-----------------------
<asp:ControlParameter ControlID="membertype" Name="isadmin" Type="string" PropertyName="text" />
-----------------------
UpdateCommand="UPDATE UserManagement SET UserName = @.UserName, Password = @.Password, FullName = @.FullName, Description = @.Description, UserID = @.UserID ,isadmin=@.isadmin,usercitycode=@.location WHERE (UserID = @.Original_UserID)"
note that the type of the "isadmin" field is "nvarchar(50)"
thanks,
M.H.H
Have you considered using a RadioButtonList control instead? With this, you can bind the SelectedValue property to your Parameter.
|||thanks for your reply,
no i dont use radiobuttonlist because it doesnt have any groupname property.
so i want to join two radio buttons.
i dont know how can i do this because im starter.
thanks,
M.H.H
No comments:
Post a Comment