Wrox Programmer Forums
Go Back   Wrox Programmer Forums > C# and C > C# 4.0 aka C# 2010 > BOOK: Beginning Visual C# 2010
|
BOOK: Beginning Visual C# 2010
This is the forum to discuss the Wrox book Beginning Visual C# 2010 by Karli Watson, Christian Nagel, Jacob Hammer Pedersen, Jon D. Reid, Morgan Skinner, ; ISBN: 9780470502266
Welcome to the p2p.wrox.com Forums.

You are currently viewing the BOOK: Beginning Visual C# 2010 section of the Wrox Programmer to Programmer discussions. This is a community of software programmers and website developers including Wrox book authors and readers. New member registration was closed in 2019. New posts were shut off and the site was archived into this static format as of October 1, 2020. If you require technical support for a Wrox book please contact http://hub.wiley.com
 
Old October 24th, 2011, 07:54 AM
Authorized User
 
Join Date: Sep 2011
Posts: 24
Thanks: 7
Thanked 0 Times in 0 Posts
Default Ch10Ex01 Can someone explain this query

In the MyClass.cs example


private MyClass:this("Default Name") {}
For what this is used for?
 
Old October 25th, 2011, 02:46 AM
Wrox Author
 
Join Date: Sep 2010
Posts: 175
Thanks: 3
Thanked 53 Times in 53 Posts
Default

with a constructor after the ":" is the constructor initializer. With "this" you access another constructor in the same class, here the constructor with a string argument.
__________________
Christian
CN innovation
Visit my blog at: csharp.christiannagel.com
Follow me on twitter: @christiannagel
The Following User Says Thank You to ChristianNagel For This Useful Post:
arun_babu_a (October 26th, 2011)





Similar Threads
Thread Thread Starter Forum Replies Last Post
Delegates - can anyone REALLY explain them? sirab33 BOOK: Beginning iOS 4 Application Development 3 May 30th, 2011 03:46 PM
could any one explain this code for me ? method Access VBA 1 August 13th, 2005 02:02 AM
explain please rein Javascript 3 January 31st, 2005 09:47 AM
Could somebody explain this to me, please? czambran BOOK: Beginning PHP, Apache, MySQL Web Development ISBN: 978-0-7645-5744-6 3 June 7th, 2004 04:05 PM
could any one explain this query to me somanchivasu Access 3 April 6th, 2004 08:23 PM





Powered by vBulletin®
Copyright ©2000 - 2020, Jelsoft Enterprises Ltd.
Copyright (c) 2020 John Wiley & Sons, Inc.