Solved

Create a Class. How? Urgent.

Posted on 2000-03-18
3
217 Views
Last Modified: 2010-04-02
I am using Borland C++ Builder.
I want to create a class, inherited from TRect Class. How do I do it and where do i Save it to use it later.
The class I am trying to create is a rectangle with arrows in it.
0
Comment
Question by:pcb69
  • 2
3 Comments
 
LVL 5

Accepted Solution

by:
laeuchli earned 50 total points
ID: 2631498
I assume you are talking about C++. This is easy.
Class Test:TRect
{
public:
private:
protected:
};
0
 
LVL 5

Expert Comment

by:laeuchli
ID: 2631500
just put this in a include file, and and include it with #include"test.h" in your main program.
0
 
LVL 22

Expert Comment

by:nietod
ID: 2631512
If you do that, you probably want to publiclly inherit from TRect.

However, depending on what you _really_ want to do, there is a good chance that you don't really want to enherit from TRect at all.
0

Featured Post

Do You Know the 4 Main Threat Actor Types?

Do you know the main threat actor types? Most attackers fall into one of four categories, each with their own favored tactics, techniques, and procedures.

Join & Write a Comment

Templates For Beginners Or How To Encourage The Compiler To Work For You Introduction This tutorial is targeted at the reader who is, perhaps, familiar with the basics of C++ but would prefer a little slower introduction to the more ad…
C++ Properties One feature missing from standard C++ that you will find in many other Object Oriented Programming languages is something called a Property (http://www.experts-exchange.com/Programming/Languages/CPP/A_3912-Object-Properties-in-C.ht…
The viewer will learn how to pass data into a function in C++. This is one step further in using functions. Instead of only printing text onto the console, the function will be able to perform calculations with argumentents given by the user.
The viewer will learn how to user default arguments when defining functions. This method of defining functions will be contrasted with the non-default-argument of defining functions.

760 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

18 Experts available now in Live!

Get 1:1 Help Now