how to increment the dropdownlist value using asp.net

Posted by Venky.Net under ASP.NET on 8/28/2012 | Points: 10 | Views : 2291 | Status : [Member] | Replies : 2
hi
i have one dropdownlist the drop down list first value 'pl-0'
example
first time execute'pl-0'
next time dropdown loading 'pl-1'
how to incrment




Responses

Posted by: Nkkppp on: 8/28/2012 [Member] Starter | Points: 25

Up
0
Down
Hi Venky,

Can you please elaborate on you query.

Do you want to increment the value every time the page loads or did you place any button control to change the value.

Regards,
Prathap.

Venky.Net, if this helps please login to Mark As Answer. | Alert Moderator

Posted by: Saratvaddilli on: 8/28/2012 [Member] [MVP] Bronze | Points: 25

Up
0
Down
write in code behind 




if(!IsPostBack)

{

int iValue = 100;// your value

while(iValue <= 100)

{

ddlSelectSF.Items.Add(iValue.ToString());

iValue += 1;

}

}


Thanks and Regards
V.SaratChand
Show difficulties that how difficult you are

Venky.Net, if this helps please login to Mark As Answer. | Alert Moderator

Login to post response