James Wilson
James Wilson

Reputation: 5150

Taking over a DotNetNuke website. Getting errors

The project was saved as a website. I am VPNing to the server and opening it from my machine.

When trying to build I am getting 60 errors (all are the same).

Class.Property.get must declare a body because it is not marked abstract or extern
Class.Property.set must declare a body because it is not marked abstract or extern

I spent hours yesterday going through so many SO questions that reported the same error and it kept leading to more and different errors. So I figured perhaps maybe it was my lack of knowledge on DotNetNuke and reset everything back to scratch in hopes maybe someone will recognize where I could have went wrong.

This is one of the properties reporting the error (15 in total each with get;set)

public int CreditScore{ get; set; }

I open up VS click File - Open - Website and give it the path to the website on the VPN. It opens in VS just fine.

My Page Properties for the project are: (If any other info is valuable from here just let me know)

.Net Framework 2.0

I've never worked with DotNetNuke before so I am hoping there is just some configuration issues I need to make and it will build just fine.

Upvotes: 0

Views: 54

Answers (1)

Igor
Igor

Reputation: 15893

The code was written in a version of .NET that allowed:

public int SomeProperty { get; set; }

(.NET 3.5 or 4.0?)

And you are compiling it with the version that does not do auto-backing of properties with fields.

Upvotes: 1

Related Questions