我有一个简单的类,它以这种方式有一个构造函数:
public Components(int sNo, string componentName, string fileType, **decimal size**, int totalDownloads, string filePath, **decimal price**, string description)
Run Code Online (Sandbox Code Playgroud)
我试图通过调用此声明来发送参数:
new DatabaseObjects.Components(1, "CC Cleaner", "exe", **2,84**, 0, @"C:\Users\admin\Desktop\Software_Components\CCCleaner.exe", **5,00**, "To clean up junk files and invalid Registry entries")
Run Code Online (Sandbox Code Playgroud)
但正如你所看到的那样,当我尝试以这种方式发送参数时,它不会将2,84作为一个值,它将2作为一个参数而84作为一个参数.
当我尝试更换时,用.我的意思是2,84为2.84
它是说不能将double转换为十进制.
我怎么解决这个问题 ?
请帮我
| 归档时间: |
|
| 查看次数: |
5639 次 |
| 最近记录: |