none
Object reference not set to an instance of an object. RRS feed

  • Question

  • Hi, i encounter this days ago but til today i can't solve the problem.

    The error are new to me and my teammate and due to this i couldnt run my code/edit.

    so when i was going to open my View> account  > register. All my  cshtml cannot run and keep showing error " The operation could not be completed" or " Object reference not set to an instance of an object."

    Even tho i deleted the whole class, and re-open it using my friend code, the same error happen.

    I really need help in solving as my work submittion date is next week

    Monday, January 15, 2018 5:58 AM

All replies

  • Object reference not set to an instance of an object.

    class vs object vs instanced

    A class is a blueprint for an object. A class is instanced into an object. When class is instanced into an object, usually by using the new keyword, it lives in memory.

    The link talks about the principles of OOP, and Java and .NET are OO language platforms.

    http://alfredjava.wordpress.com/2008/07/08/class-vs-object-vs-instance/

    Basically, your code is trying to reference/access an object that is not there in memory for whatever reasons that you'll have to debug your code with the debugger to find out why.

    ASP.NET MVC can be discussed at the ASP.NET forums.

    http://forums.asp.net/

    • Proposed as answer by Cor Ligthert Monday, January 15, 2018 9:03 AM
    Monday, January 15, 2018 8:08 AM