Solved

Create a Class. How? Urgent.

Posted on 2000-03-18
3
224 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 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

Free Tool: Port Scanner

Check which ports are open to the outside world. Helps make sure that your firewall rules are working as intended.

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

Article by: SunnyDark
This article's goal is to present you with an easy to use XML wrapper for C++ and also present some interesting techniques that you might use with MS C++. The reason I built this class is to ease the pain of using XML files with C++, since there is…
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 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 how to user default arguments when defining functions. This method of defining functions will be contrasted with the non-default-argument of defining functions.

730 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