开发者

Insert checkbox checked value when checked to textbox as comma seperated string

开发者 https://www.devze.com 2023-01-24 16:42 出处:网络
Insert checkbox checked value when checked to textbox as comma seperated string in vb.net or javascript

Insert checkbox checked value when checked to textbox as comma seperated string in vb.net or javascript

suppose i have 3 checkboxes and and 1 textboxes in my webpage.aspx

when i checked checkbox1 and checkbox2 then in textbox it will appear as 1,2 only on checkboxes checked event ...

and i want its revert also :

if i set textbox 开发者_C百科de


It should pretty straight forward

Checkbox should have the following event

OnCheckedChanged see here for more reference http://www.w3schools.com/aspnet/control_checkbox.asp.

In that event update the textbox count , like that bind the events and whenever event is changed please update the text box.

 textbox.Text=""; // textbox should be the id of textbox control

it should be pretty straigforwad

as you didn't provide too many details , i am providing you an approach

0

精彩评论

暂无评论...
验证码 换一张
取 消