非法表达 [英] illegal start of expression
本文介绍了非法表达的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!
问题描述
static void AddNewCustomer()
{
try
{
int id;
String UniqCustID, uniqcustid, newcust, UniqueNumber;
do
{
UniqCustID = "Please enter unique customer id : ";
uniqcustid = JOptionPane.showInputDialog( UniqCustID );
UniqueNumber(id, newcust);
if (UniqueNumber(id, newcust) == false)
{
JOptionPane.showMessageDialog(null, "Customer id already exists or you entered a number less than 1!");
}
我在静态void AddNewCustomer()处收到该错误,为什么呢?
im getting that error at static void AddNewCustomer()...why is that? is syntax correct?
推荐答案
这是完整的代码吗?
您可能在某处缺少大括号(},或者在某处缺少一个或多个不必要的大括号.
Is that the complete code?
You''re probably missing a curly bracket ( } ) somewhere, or maybe you have one or more unneccesary curly brackets somewhere.
您发布的代码部分不完整,因为您现在可以看到我已将其重新格式化.也没有办法知道错误语句之前的内容.请张贴前面的行,以便我们为您提供帮助.
The portion of code that you have posted is incomplete, as you can see now that I have reformatted it. There is also no way of knowing what you have before the statement in error. Please post the preceding lines so that we may assist you.
我已将语法添加为消息.请在那里查看.谢谢:)
I have added the syntax as a message. Please view it there. thanks :)
这篇关于非法表达的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!
查看全文