user3503644
user3503644

Reputation: 77

cannot implicitly convert type void to object

I work with MVVM and i have this error

private Student _student;

public void  inserstudent 
{
    set{ __student=_studentService.InsetStudent(_student); }
}

Upvotes: 1

Views: 438

Answers (1)

user1228
user1228

Reputation:

private Student _student;

public void  inserstudent 
{
    set{ _student=_studentService.InsetStudent(value); }
}

Assuming that _studentService.InsetStudent returns the student. Other than that, I could see this going wrong about four different ways.

I think the issue is that you have an extremely tenuous grasp of programming C# :/

Immediately grab a copy of CLR Via C# by Jeffrey Richter and start reading. Skip the first two chapters, tho.

Upvotes: 1

Related Questions