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
Sharad Gupta
93
19.7k
8.6m
static method problem
Apr 24 2014 2:35 AM
suppose i create a class
like
namespace x
{
class a
{
public SqlConnection getcon()
{
................some code
}
}
}
and i want to use it another application
i just add reference of that class
using x;
class b:a
{
public void xyz()
{
and i just use the getcon() method
}
but when i create static method like
static xys()
{
here we want to create the obj of "a" class then i use it why?
like a obj = new a();
obj.getcon(); {why?}
}
}
Reply
Answers (
1
)
Validation of textbox for decimal numbers
How to insert more than one id to a row in sql using c# code