TECHNOLOGIES
FORUMS
JOBS
BOOKS
EVENTS
INTERVIEWS
Live
MORE
LEARN
Training
CAREER
MEMBERS
VIDEOS
NEWS
BLOGS
Sign Up
Login
No unread comment.
View All Comments
No unread message.
View All Messages
No unread notification.
View All Notifications
Answers
Post
An Article
A Blog
A News
A Video
An EBook
An Interview Question
Ask Question
Forums
Monthly Leaders
Forum guidelines
L A
NA
170
171.2k
Object reference not set to an instance of an object.
May 10 2018 11:33 PM
Hi,
I'm working on a console application which also have class library in it.
I added refrence of class library to console project as show above. In class library i have following code.
namespace
SomeClass
{
public
class
ClassOne
{
public
string[] SupportedFiles;
}
}
And in console app, program.cs, i'm trying to assign SupportedFiles.
class
Program
{
public
ClassOne class1 { get; set; }
public
Program()
{
class1.SupportedArchitectures =
new
string[] {
"Test"
,
"Test"
};
}
}
But line number 6 class1.SupportedArchitectures = new string[] { "Test", "Test" }; throws an error.
What am i missing? Am I so dumb instantiating a string array. Please help me out
Reply
Answers (
1
)
How do i convert string 2018-05-10T14:29:00 to MM/dd/yyyy
KeyPress event in ComboBox