I've been writing VB.net for yonks, but have been thrown a c# project to work on. Pretty much sussed it apart from one little problem.
I have a Linq populated dataview with a label in it. The db returns a bit field to populate. I want to convert the "True" / "False" returned by the db to "Y" / "N".
How hard can it be?? Well I've been pouring over it for ages......
Here is the label:
<asp:Label ID="Label1" runat="server" Text='<%# DoYN(Eval("Paid")) %>'></asp:Label>
and my DoYN function
public string DoYN(string Paid)
if ((Paid.Trim() == "True"))
else if ((Paid.Trim() == "False"))
But I get the following error:
The best overloaded method match for DoYNstring) has some invalid arguments.
Anyone shed any light on this please?