Articles   Members Online:
-Article/Tip Search
-News Group Search over 21 Million news group articles.
-Delphi/Pascal
-CBuilder/C++
-C#Builder/C#
-JBuilder/Java
-Kylix
Member Area
-Home
-Account Center
-Top 10 NEW!!
-Submit Article/Tip
-Forums Upgraded!!
-My Articles
-Edit Information
-Login/Logout
-Become a Member
-Why sign up!
-Newsletter
-Chat Online!
-Indexes NEW!!
Employment
-Build your resume
-Find a job
-Post a job
-Resume Search
Contacts
-Contacts
-Feedbacks
-Link to us
-Privacy/Disclaimer
Embarcadero
Visit Embarcadero
Embarcadero Community
JEDI
Links
How to give a MDI application a 3D frame Turn on/off line numbers in source code. Switch to Orginial background IDE or DSP color Comment or reply to this aritlce/tip for discussion. Bookmark this article to my favorite article(s). Print this article
21-Oct-02
Category
Others
Language
Delphi All Versions
Views
59
User Rating
No Votes
# Votes
0
Replies
0
Publisher:
DSP, Administrator
Reference URL:
DKB
			Author: Jonas Bilinkevicius

How to give a MDI application a 3D frame

Answer:

You can give an MDI application a 3D frame in Delphi by overriding the main form's 
CreateWnd method:

1   procedure TMainForm.CreateWnd;
2   begin
3     inherited CreateWnd;
4     SetWindowLong(ClientHandle, GWL_EXSTYLE, GetWindowLong(ClientHandle, GWL_EXSTYLE)
5       or WS_EX_CLIENTEDGE);
6   end;


In the interface section of your main form's unit you have a type definition for 
the main form that
looks something like:

7   type
8     TMainForm = class(TForm)
9       { maybe some field are defined here }
10    private
11      { private declarations }
12    public
13      { public declarations }
14    end;


Add the following two lines immediately preceding the end:

protected

procedure CreateWnd; override;

Now add that procedure that I gave you in the implementation section of the unit:

15  procedure TMainForm.CreateWnd;
16  begin
17    inherited CreateWnd;
18    SetWindowLong(ClientHandle, GWL_EXSTYLE, GetWindowLong(ClientHandle, GWL_EXSTYLE)
19      or WS_EX_CLIENTEDGE);
20  end;


			
Vote: How useful do you find this Article/Tip?
Bad Excellent
1 2 3 4 5 6 7 8 9 10

 

Advertisement
Share this page
Advertisement
Download from Google

Copyright © Mendozi Enterprises LLC