How to write a shape panel

Posted on 2001-08-08
Medium Priority
Last Modified: 2010-04-06
How to write a shape panel like Office Assistant done?
Any component could be use?


Question by:shekou
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
LVL 34

Accepted Solution

Slick812 earned 100 total points
ID: 6366751
hello shekou, you can set the amount of a control or form that you can see with a "Region". A region tells windows OS what part is allowed to be used (visible and gets mouse clicks). you can set the region in the Forms OnCreate event. This will make Panel1 Elipitcal - - - -

    { Private declarations }
    Rgn1 : HRGN;

procedure TForm1.FormCreate(Sender: TObject);
Rgn1 := CreateEllipticRgn(Panel1.BoundsRect.Left-Panel1.Left, Panel1.BoundsRect.Top-Panel1.Top, Panel1.BoundsRect.Right-Panel1.Left, Panel1.BoundsRect.Bottom-Panel1.Top);
  SetWindowRgn(Panel1.Handle, Rgn1, TRUE);

// be sure to Release the Region
procedure FormDestroy(Sender: TObject);

you can create Regions of many different shapes

Author Comment

ID: 6501887
tried, but not work.



Featured Post

Enroll in August's Course of the Month

August's CompTIA IT Fundamentals course includes 19 hours of basic computer principle modules and prepares you for the certification exam. It's free for Premium Members, Team Accounts, and Qualified Experts!

Question has a verified solution.

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

A lot of questions regard threads in Delphi.   One of the more specific questions is how to show progress of the thread.   Updating a progressbar from inside a thread is a mistake. A solution to this would be to send a synchronized message to the…
Objective: - This article will help user in how to convert their numeric value become words. How to use 1. You can copy this code in your Unit as function 2. than you can perform your function by type this code The Code   (CODE) The Im…
Michael from AdRem Software explains how to view the most utilized and worst performing nodes in your network, by accessing the Top Charts view in NetCrunch network monitor (https://www.adremsoft.com/). Top Charts is a view in which you can set seve…
Visualize your data even better in Access queries. Given a date and a value, this lesson shows how to compare that value with the previous value, calculate the difference, and display a circle if the value is the same, an up triangle if it increased…
Suggested Courses

801 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