Reputation: 123
I am getting this error bc30205 end of statement expected at the line below of my code. Any suggestion to fix this particular issue?
<td style="width:20%">
<asp:Label ID="lblDoseStrength" runat="server" Text='<%# If(IsDbNull(Eval("Value.DoseStrength1")), " ", Eval("Value.DoseStrength1")) + " " + If(IsDbNull(Eval("Value.DoseUnit1")), " ", Eval("Value.DoseUnit1")) + " " + If(IsDbNull(Eval("Value.DoseForm1")), " ", Eval("Value.DoseForm1")) + " " + If(IsDbNull(Eval("Value.DoseMult1")), " ", Eval("Value.DoseMult1"))) %>'></asp:Label>
</td>
Upvotes: 1
Views: 3293
Reputation: 9193
You should remove the final parenthesis. Change to this:
<asp:Label ID="lblDoseStrength" runat="server" Text='<%# If(IsDbNull(Eval("Value.DoseStrength1")), " ", Eval("Value.DoseStrength1")) + " " + If(IsDbNull(Eval("Value.DoseUnit1")), " ", Eval("Value.DoseUnit1")) + " " + If(IsDbNull(Eval("Value.DoseForm1")), " ", Eval("Value.DoseForm1")) + " " + If(IsDbNull(Eval("Value.DoseMult1")), " ", Eval("Value.DoseMult1")) %>'></asp:Label>
Upvotes: 2