0
cboMethod.DataSource = Enum.GetNames(typeof(Method));
標識有望與組合框
Console.WriteLine("Starting payment with a specific method ...");
status = mollieClient.StartPayment(new Payment
{
amount = decimal.Parse(lblPrijs.Text),
method = Method.(cboMethod.SelectedItem.ToString()),
description = "Test payment",
redirectUrl = "http://www.lynx-automation.be/"
});
的Method.
後是一個小紅線說標識符。我的組合框中選定的項目應該是該標識符。我究竟做錯了什麼?
對不起,修復了! – cubrr 2015-03-19 07:49:09
@ extreme4all你不應該通過編輯回覆答案。這是什麼意見。 – cubrr 2015-03-19 07:51:36
對不起,我coudnt獲得「黃色框」周圍的錯誤 >錯誤\t \t 1「Mollie.Api.Method」是「類型」,但使用類似「變量」 \t >錯誤\t \t 2最好'System.Enum.Parse(System.Type,string)'的重載方法匹配有一些無效參數\t >錯誤參數1:無法從'Mollie.Api.Method'轉換爲'System.Type' – extreme4all 2015-03-19 07:52:26