我收到错误“}预期”在下面的代码行中它是一行 [英] I am getting error "} expected " in the following line of code its a single line

查看:63
本文介绍了我收到错误“}预期”在下面的代码行中它是一行的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

以下行有错误。可能有人指出错误,因为我是c#的新手。谢谢

branch.BindBranch(ddlbranch,Convert.ToInt32(Session [AdminMainBranchId])); ddlbranch,Convert.ToInt32(Session [AdminMainBranchId]));



我尝试过:



i试图删除分号,括号并尝试将其分成两行但没有解决方案。

the following line has the error. could some one point out the mistake as i am new to c#. Thanks
branch.BindBranch(ddlbranch,Convert.ToInt32( Session["AdminMainBranchId"])); ddlbranch,Convert.ToInt32( Session["AdminMainBranchId"]));

What I have tried:

i have tried removing semicolon, brackets and tried to make it in two lines but no solution.

推荐答案

FROM:

FROM:
branch.BindBranch(ddlbranch,Convert.ToInt32( Session["AdminMainBranchId"])); ddlbranch,Convert.ToInt32( Session["AdminMainBranchId"]));



TO:


TO:

branch.BindBranch(ddlbranch,Convert.ToInt32( Session["AdminMainBranchId"]));



删除:

ddlbranch,Con vert.ToInt32(Session [AdminMainBranchId]));


REMOVE:
ddlbranch,Convert.ToInt32( Session["AdminMainBranchId"]));


在那行之上的某个地方你有{并且它是编译器寻找匹配的闭包}。
Somewhere above that line you have a { and it's the compiler looking for closure with a matching }.


Quote:

我收到错误}期望在下面的代码行中它的单行

I am getting error "} expected " in the following line of code its a single line



编译器告诉您,当他到达此行时,它会检测先前代码中的错误。因此,此行的包含与错误消息无关。


The compiler tells you that when he reach this line, it detect a mistake in previous code. So the contain of this line is not related to the error message.


这篇关于我收到错误“}预期”在下面的代码行中它是一行的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆