943,824 Members | Top Members by Rank

Ad:
  • C# Discussion Thread
  • Unsolved
  • Views: 2763
  • C# RSS
Oct 9th, 2008
0

different syntax for extending a class?

Expand Post »
I was looking at a tutorial for when you extend a class. One tutorial said you used a keyword extends between the two class names and another tutorial said you used a period between the two class names to join the two classes together. Both of them are c# tutorials.

Not that it's a big deal, but are they both correct? They both seem to be decent tutorials for the most part. I'm sort of doing a side by side comparison with 2 tutorials. Sometimes one of the tutorials will explain something better than the other and vice versa.

Thanks in advance
Similar Threads
Reputation Points: 10
Solved Threads: 0
Newbie Poster
legend_018 is offline Offline
4 posts
since Oct 2008
Oct 10th, 2008
0

Re: different syntax for extending a class?

Hi,

Quote ...
One tutorial said you used a keyword extends between the two class names
In C#, we use colon ( : ) to extend from one class. Java language uses this extends keyword to inherit from a class.

If u have doubt like this, try it practically with these two types. You get the Answer
Last edited by selvaganapathy; Oct 10th, 2008 at 12:16 am.
Reputation Points: 44
Solved Threads: 101
Posting Pro
selvaganapathy is offline Offline
547 posts
since Feb 2008
Oct 10th, 2008
0

Re: different syntax for extending a class?

perhaps what you saw on the tutorial (link it if you could) was something where it was taking "myapp.myclass" and extending it.. where where myapp is the name space and myclass being the actual class being extended
Reputation Points: 196
Solved Threads: 190
Posting Virtuoso
LizR is offline Offline
1,735 posts
since Aug 2008

This thread is more than three months old

No one has posted to this discussion for at least three months. Please let old threads die and do not reply to them unless you feel you have something new and valuable to contribute that absolutely must be added to make the discussion complete. Otherwise, please start a new thread in this forum instead.
Message:
Previous Thread in C# Forum Timeline: Best Practices
Next Thread in C# Forum Timeline: Problems with databindings





About Us | Contact Us | Advertise | Acceptable Use Policy
Forum Index | Build Custom RSS Feed


Follow us on Twitter


© 2011 DaniWeb® LLC