Click here to Skip to main content
15,896,474 members
Please Sign up or sign in to vote.
0.00/5 (No votes)
See more:
SQL
SELECT op_need_name 
FROM ces_v_skill_operation_name 
WHERE oper_need_code in (SELECT DISTINCT oper_need_code FROM ces_skill_style_master WHERE fg_mat_no = '" + (ValueDescriptionPair)ddstyle.SelectedItem.Value + "')AND critical_code ='B'




When i compile the code i got the error like this


MSIL
Error   1   Cannot convert type 'string' to 'ValueDescriptionPair' 



Pls help somebody

Thanks in advance
Posted
Updated 5-May-10 23:18pm
v2

1 solution

You're trying to convert an intrinsic type to a complex type. You can't do that.

Change this:

(ValueDescriptionPair)ddstyle.SelectedItem.Value


to this:

ddstyle.SelectedItem.Value.ToString()





 
Share this answer
 

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