Click here to Skip to main content
16,021,112 members
Please Sign up or sign in to vote.
0.00/5 (No votes)
See more:
Hello,

I am doing my project using C# ASP.NET. At the formview1 at the insert item template I have a control jobTitleDropdownlist. Where I have edited it's item by a method.
C#
DropDownList ddl = (DropDownList)FormView1.FindControl("jobTitleDropDownList");
ddl.Items.Clear();
ddl.Items.AddRange(modelObj.getMiscStatusItem("Job Title"));


Here modelObj.getMiscStatusItem("Job Title") returns an array of a list item. I got all the item to my dropdown list.
But after insertion the suppliers table is only inserting with the first element of the jobTitle dropdownlist 'SalesManager'.
What should I change here.

Can anybody give me another good idea to do this?
Posted
Updated 12-Sep-10 10:34am
v2

1 solution

I think ur going to store "job title " in suplier table , if am right !!!

use SelectedValue property of ddl to insert ur selected "job title".
 
Share this answer
 
Comments
jamil_2342 14-Sep-10 11:49am    
Thank you .

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900