Possible Duplicate:
The type of the conditional expression can not be determined?奇怪的錯誤使用?操作
我目前寫了這樣一句話:
byte? Col_8 = (Rad_8.SelectedValue == null) ? null : byte.Parse(Rad_8.SelectedValue);
,但它有這個錯誤:
Type of conditional expression cannot be determined because there is no implicit conversion between
'<null>'
and'byte'
爲什麼我可以?
後使用空?如果沒有if
聲明,相當於上述代碼呢?
什麼是Rad_8.SelectedValue類型? – CharlesB 2012-01-09 11:55:22