473,387 Members | 3,033 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,387 software developers and data experts.

Which template should I use for classes

I'm developing a program that I want to be Object Oriented, so I've
opened the Add New File dialog, and there I found "Component Class" and
"Installer Class", which of them should I use to create the classes for
my program logic?

May 29 '06 #1
2 874

"Juliano.net" <ju*********@gmail.com> wrote in message
news:11*********************@g10g2000cwb.googlegro ups.com...
I'm developing a program that I want to be Object Oriented, so I've
opened the Add New File dialog, and there I found "Component Class" and
"Installer Class", which of them should I use to create the classes for
my program logic?


none of those for a simple class.
select 'add class' then select the C++ tab and add a C++ class. you can
choose between Managed (.NET) and plain C++.
that will generate the header and source files for your class.

if you are using 'add new file' you can add a new header file and cpp file
and then create the class declaration and implementation yourself, but the
end result will be the same. I just mention this to show that there is
nothing inherently different between adding a class manually and using the
wizard.
--

Kind regards,
Bruno van Dooren
br**********************@hotmail.com
Remove only "_nos_pam"
May 30 '06 #2

"Bruno van Dooren" <br**********************@hotmail.com> wrote in message
news:OM**************@TK2MSFTNGP02.phx.gbl...

"Juliano.net" <ju*********@gmail.com> wrote in message
news:11*********************@g10g2000cwb.googlegro ups.com...
I'm developing a program that I want to be Object Oriented, so I've
opened the Add New File dialog, and there I found "Component Class" and
"Installer Class", which of them should I use to create the classes for
my program logic?
none of those for a simple class.
select 'add class' then select the C++ tab and add a C++ class. you can
choose between Managed (.NET) and plain C++.
that will generate the header and source files for your class.


That's what I do as well, however going the "Component Class" route doesn't
add much extra code at all (about 6 lines) and it lets you add the resulting
class to your forms and set the properties and event handlers using the
designer... so you may consider that for public classes.
if you are using 'add new file' you can add a new header file and cpp file
and then create the class declaration and implementation yourself, but the
end result will be the same. I just mention this to show that there is
nothing inherently different between adding a class manually and using the
wizard.
--

Kind regards,
Bruno van Dooren
br**********************@hotmail.com
Remove only "_nos_pam"

May 30 '06 #3

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

12
by: Me | last post by:
Hi, I would like learn from people with experience in C++, which of the following styles of way to construct "get/set" member functions would be the best in terms of usability, speed, et cetera. ...
21
by: Sebastian Faust | last post by:
Hi, is a construction like the following possible: template<class view_model> class template_clase { protected: template_clase() {} virtual ~template_clase() {}
1
by: Oplec | last post by:
Hi, I'm learning C++ as a hobby using The C++ Programming Language : Special Edition by Bjarne Stroustrup. I'm working on chpater 13 exercises that deal with templates. Exercise 13.9 asks for me...
2
by: Agent Mulder | last post by:
Hi group, I try to get a reference to a template. In the template, a virtual function is declared. Later in the program, I inherit from classes created by the template. So the template is the...
5
by: nifsmith | last post by:
Hi I am trying to learn about Queues and use templates at the same time. I have written the following code and I am getting a link error, stating "unresolved external symbol, "int__cdecl...
18
by: Erik Arner | last post by:
Hi, I really need some help here. After upgrading to g++ 3.4 I have run into all sorts of troubles that I'm sure depends on my lack of proper understanding of C++. I would now like to get it right...
3
by: Serge Skorokhodov (216716244) | last post by:
Hi, I just seeking advice. Some background information first because I've run into issues that seems pretty obscure to me:( Quick search through KB yields next to nothing. Simplified samples...
14
by: J.S. | last post by:
In a Windows Form application, which is the better method to concatenate large blocks of code? 1. Reading the text from text files. 2. Adding the text to the VB file itself? Thanks! J.S. ...
2
by: Damien | last post by:
Hi all, I'm messing around with various signal/slot mechanisms, trying to build something lean and fast. I've used libsigc++, and Sarah Thompson's at sigslot.sourceforge.net, and most of the...
5
by: StephQ | last post by:
This is from a thread that I posted on another forum some days ago. I didn't get any response, so I'm proposing it in this ng in hope of better luck :) The standard explanation is that pointer...
0
by: taylorcarr | last post by:
A Canon printer is a smart device known for being advanced, efficient, and reliable. It is designed for home, office, and hybrid workspace use and can also be used for a variety of purposes. However,...
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
0
by: ryjfgjl | last post by:
If we have dozens or hundreds of excel to import into the database, if we use the excel import function provided by database editors such as navicat, it will be extremely tedious and time-consuming...
0
by: ryjfgjl | last post by:
In our work, we often receive Excel tables with data in the same format. If we want to analyze these data, it can be difficult to analyze them because the data is spread across multiple Excel files...
0
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
0
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
0
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.