What is an object reference in C#?

Experience Level: Junior
Tags: C#

Answer

When you create an object, it gets stored to memory. In the source code the newly created objects are assigned to variables. But in many cases the variable doesn't hold the whole object. It holds just link to a location in memory where the object is stored. This link is called an object reference because it refers to a location in memory where the object is stored.

Comments

No Comments Yet.
Be the first to tell us what you think.
C# for beginners
C# for beginners

Are you learning C# ? Try our test we designed to help you progress faster.

Test yourself