Click here to Skip to main content
15,885,767 members
Please Sign up or sign in to vote.
1.00/5 (1 vote)
See more:
public void countstid()
{
DBaccess c = new DBaccess();
c.connect();
countstid = c.membercount("tblstudent", ("stid==" + _stid + ""));
c.disconnect();
}

What I have tried:

public void countstid()
{
DBaccess c = new DBaccess();
c.connect();
countstid = c.membercount("tblstudent", ("stid==" + _stid + ""));
c.disconnect();
}


asp.net in c#
Posted
Updated 28-Dec-17 8:17am
Comments
Thomas Daniels 28-Dec-17 6:30am    

1 solution

You are trying to assign a value to countstid but you cannot. You have declared countstid as a method with no return value (void).

I suggest you go through some C# tutorials and get a good basic understanding first.
 
Share this answer
 

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900