Hi I want to allow user to add new country names in combo box if his/her desired country is not listed in combo box. so next time this value should be add in combo box as well. I want to do this using c sharp. Kindly guide me.
Assuming you mean winforms:
These will only be available locally. On a Button-Click, save the data to one of these:
- Textfile
- XML-file
- SQLCE Database
You should find more than enough tutorials with a your-favorite-search-engine-search like "c# save and read data to X"
When you read the data again, simply add it to your combobox using combobox.items.add("country");
oor use the DataSource
-property.
Assuming you mean ASP.net:
Save them to your database.
精彩评论