Solved

Autohide Taskbar

Posted on 2001-06-24
13
547 Views
Last Modified: 2010-04-06
Hello how do i make the taskbar auto hide during runtime?
0
Comment
Question by:jchua
  • 4
  • 3
  • 3
  • +2
13 Comments
 
LVL 13

Expert Comment

by:Epsylon
ID: 6223505
This is not possible.
0
 
LVL 4

Expert Comment

by:jsweby
ID: 6223606
Yes it is. Button1 hides the taskbar, button2 shows it again.

procedure TForm1.Button1Click(Sender: TObject);
var
   hTaskbar: THandle;
begin
     hTaskbar := FindWindow('Shell_TrayWnd', Nil);
     ShowWindow(hTaskbar, SW_HIDE);
end;

procedure TForm1.Button2Click(Sender: TObject);
var
   hTaskbar: THandle;
begin
     hTaskbar := FindWindow('Shell_TrayWnd', Nil);
     ShowWindow(hTaskbar, SW_SHOWNORMAL);
end;

J.
0
 
LVL 13

Expert Comment

by:Epsylon
ID: 6223664
That is 'hiding' the taskbar, not 'turning on autohide', which I think jchua wants...
0
 
LVL 4

Expert Comment

by:jsweby
ID: 6223672
Epsylon, I think I see your point although I'm sure jchua is probably just looking for a way to auto-hide the taskbar when his program runs, then (maybe) show it again when it finishes. You're right though, I've found no way of actually turning the "auto-hide" feature on and off.

J.
0
 
LVL 22

Expert Comment

by:mnasman
ID: 6223783
Hello

 Epsylon, I don't think that's Imposible, I think that can done by SHAppBarMessage API with ABM_SETAUTOHIDEBAR, but I really didn't that, take a look at microsoft site
http://msdn.microsoft.com/library/default.asp?url=/library/en-us/shellcc/platform/Shell/Messages/ABM_SETAUTOHIDEBAR.asp

and look at the win32 sdk help file for SHAppBarMessage api

Mohammed Nasman
0
 
LVL 13

Accepted Solution

by:
Epsylon earned 150 total points
ID: 6223826
Mohammed, that won't work 'cause the taskbar is protected from that.
0
Do You Know the 4 Main Threat Actor Types?

Do you know the main threat actor types? Most attackers fall into one of four categories, each with their own favored tactics, techniques, and procedures.

 
LVL 22

Expert Comment

by:mnasman
ID: 6223841
I saw a code for access the task bar, but it was not in delphi, and I lost the link cuz i'm not interested in vc++, i didn't remember if that api or funcation, it called accesstaskbar or register
0
 
LVL 13

Expert Comment

by:Epsylon
ID: 6224023
It is NOT POSSIBLE!

I've been searching the net for this a year ago and did NOT find a solution.
0
 
LVL 4

Expert Comment

by:jsweby
ID: 6224036
So then, my solution posted above is the nearest you can get to auto-hiding the taskbar. I think this is a better way anyway, you shouldn't really change the user's settings, just hide & show the taskbar when you want to.

J.
0
 
LVL 22

Expert Comment

by:mnasman
ID: 6225749
Epsylon I think you are right, as I told I dont' have a good knowledage about these API, and I thought it done by that

Mohammed
0
 
LVL 17

Expert Comment

by:inthe
ID: 6226319
quote from microsoft:

http://msdn.microsoft.com/library/default.asp?url=/library/en-us/shellcc/shellcc/shell/Shell_Int/Taskbar.asp

"
The taskbar supports two display options: Auto Hide and Always On Top. To set these options, the user
must open the taskbar shortcut menu, click Properties, and select or clear the Auto Hide check box or
the Always On Top check box. There is no way to set these options programmatically.

"
you can only make your own shappbar's autohide by using setstate function.
0
 
LVL 26

Expert Comment

by:Russell Libby
ID: 8685394
No comment has been added lately, so it's time to clean up this TA.
I will leave a recommendation in the Cleanup topic area that this question is:

Accept Epsylon's comment as answer

Please leave any comments here within the next seven days.
 
PLEASE DO NOT ACCEPT THIS COMMENT AS AN ANSWER!
 
Thank you,
Russell

EE Cleanup Volunteer
0

Featured Post

How to run any project with ease

Manage projects of all sizes how you want. Great for personal to-do lists, project milestones, team priorities and launch plans.
- Combine task lists, docs, spreadsheets, and chat in one
- View and edit from mobile/offline
- Cut down on emails

Join & Write a Comment

The uses clause is one of those things that just tends to grow and grow. Most of the time this is in the main form, as it's from this form that all others are called. If you have a big application (including many forms), the uses clause in the in…
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…
In this seventh video of the Xpdf series, we discuss and demonstrate the PDFfonts utility, which lists all the fonts used in a PDF file. It does this via a command line interface, making it suitable for use in programs, scripts, batch files — any pl…
You have products, that come in variants and want to set different prices for them? Watch this micro tutorial that describes how to configure prices for Magento super attributes. Assigning simple products to configurable: We assigned simple products…

743 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

11 Experts available now in Live!

Get 1:1 Help Now