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
Rushal Arora
NA
112
175.9k
How type casting is done between base class and derived class?
Oct 22 2012 1:25 PM
Hi Everyone,
Please let me know the solution of below question :
Q.1) How type casting is done between base class and derived class?
button_click(object sender, EventArrgs e)
Button b = (button) sender;// button class is derived from object class, for this typecasting to happen button reference must be there in object class but object class is created by microsoft so we can't see . So my question is how reference of button class is written in object class?
class Object
{
Button b;
}
class Button : Object
{}
Now can we write :
Button b = new Object();
and
Object o = new Button();
Thanks and Regards
Reply
Answers (
5
)
DataGridView ( Windows Forms )
How to filter in dataset any one name is like a name "Raja" in the dataset how to filter?