Solved

How can I make my form streach over all the screen?

Posted on 2004-03-25
12
168 Views
Last Modified: 2010-04-05
Hi guys....
How can I make my form streach over all the screen?
also over taskbar like games .

thanks
0
Comment
Question by:peruzzi
12 Comments
 
LVL 11

Accepted Solution

by:
shaneholmes earned 20 total points
Comment Utility
set the form windowstate property  to wsmaximized & BorderStyle to "bsNone"


procedure TForm1.FormCreate(Sender: TObject);
var
 TaskBar: HWND;
Begin
 TaskBar := FindWindow('Shell_TrayWnd', nil);
ShowWindow(TaskBar, SW_HIDE);
end;

procedure TForm1.FormDestroy(Sender: TObject);
var
 TaskBar: HWND;
Begin
 TaskBar := FindWindow('Shell_TrayWnd', nil);ShowWindow(TaskBar, SW_SHOW);
end;
end.

Shane
0
 
LVL 17

Expert Comment

by:mokule
Comment Utility
form1.height := screen.height;
form1.width := screen.width;
0
 
LVL 11

Expert Comment

by:shaneholmes
Comment Utility
peruzzi,

I would recommend you  place a temporary button on the form with

Close;

in the OnClick event,

then you can remove he button when your done developing your application
or when you have added an alternative method of exiting the application.

Shane
0
 
LVL 17

Expert Comment

by:mokule
Comment Utility
peruzzi
1. If You hide the taskbar like Shane advice there will be no taskbar when You switch from your application to another using Alt+Tab.
2. It is also possible to close your application by Alt+F4
0
 
LVL 11

Expert Comment

by:shaneholmes
Comment Utility
WHen you clsoe the form, you get the task bar back, see my code above

What are you trying to do here mokule?

Shane
0
 
LVL 17

Expert Comment

by:mokule
Comment Utility
I didn't talk about closing application, but switching to another.
Am I not right?
Excuse me Shane but I don't understand Your question.
0
Highfive + Dolby Voice = No More Audio Complaints!

Poor audio quality is one of the top reasons people don’t use video conferencing. Get the crispest, clearest audio powered by Dolby Voice in every meeting. Highfive and Dolby Voice deliver the best video conferencing and audio experience for every meeting and every room.

 
LVL 11

Expert Comment

by:shaneholmes
Comment Utility
Well, if i understand you correctly, you say that with my solution, you can't Alt-Tab to other apps! - and I say you can!

Shane
0
 
LVL 17

Expert Comment

by:mokule
Comment Utility
No You don't understand me.
I've just said that WHEN You switch the task bar is hidden. Nothing more.
0
 
LVL 11

Expert Comment

by:shaneholmes
Comment Utility
Right, thats correct.....

Shane
0
 
LVL 5

Expert Comment

by:Hypoviax
Comment Utility
Very easy. You don't need to do all this other fancy stuff just set the properties of the form:

- Windowstate - wsmaximised
- BorderStyle - bsnone

And if you want to have it ontop of all programs set

-FormStyle - Fsstayontop

. To bring the program to the top call

formx.bringtofront

Regards,

Hypoviax
0
 
LVL 11

Expert Comment

by:shaneholmes
Comment Utility
Whats makes yours more simple then mokule's

form1.height := screen.height;
form1.width := screen.width;

Shane
0
 

Author Comment

by:peruzzi
Comment Utility
Hi Guys
thanks for you

peruzzi
0

Featured Post

What Is Threat Intelligence?

Threat intelligence is often discussed, but rarely understood. Starting with a precise definition, along with clear business goals, is essential.

Join & Write a Comment

In this tutorial I will show you how to use the Windows Speech API in Delphi. I will only cover basic functions such as text to speech and controlling the speed of the speech. SAPI Installation First you need to install the SAPI type library, th…
Hello everybody This Article will show you how to validate number with TEdit control, What's the TEdit control? TEdit is a standard Windows edit control on a form, it allows to user to write, read and copy/paste single line of text. Usua…
Internet Business Fax to Email Made Easy - With eFax Corporate (http://www.enterprise.efax.com), you'll receive a dedicated online fax number, which is used the same way as a typical analog fax number. You'll receive secure faxes in your email, fr…
Get a first impression of how PRTG looks and learn how it works.   This video is a short introduction to PRTG, as an initial overview or as a quick start for new PRTG users.

771 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

16 Experts available now in Live!

Get 1:1 Help Now