?
Solved

Create a Class. How? Urgent.

Posted on 2000-03-18
3
Medium Priority
?
230 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
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 2
3 Comments
 
LVL 5

Accepted Solution

by:
laeuchli earned 200 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

Free Tool: Site Down Detector

Helpful to verify reports of your own downtime, or to double check a downed website you are trying to access.

One of a set of tools we are providing to everyone as a way of saying thank you for being a part of the community.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Introduction This article is a continuation of the C/C++ Visual Studio Express debugger series. Part 1 provided a quick start guide in using the debugger. Part 2 focused on additional topics in breakpoints. As your assignments become a little more …
This article shows you how to optimize memory allocations in C++ using placement new. Applicable especially to usecases dealing with creation of large number of objects. A brief on problem: Lets take example problem for simplicity: - I have a G…
The goal of the video will be to teach the user the concept of local variables and scope. An example of a locally defined variable will be given as well as an explanation of what scope is in C++. The local variable and concept of scope will be relat…
The viewer will learn additional member functions of the vector class. Specifically, the capacity and swap member functions will be introduced.
Suggested Courses

770 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