startbutton open, create or something like...

delphi package - easy access to shell apis
Post Reply
ipuiuna
Posts: 4
Joined: Sat Jun 12, 2004 3:32 pm

startbutton open, create or something like...

Post by ipuiuna »

I use startbutton.Close to close start button :wink: , I want to create button again with they normal features,
to do this i close explorer app and reopen manaly in XP, in 98 they restart automactically.
There's other a way?

sorry by my english.

Ipuiuna.
madshi
Site Admin
Posts: 10754
Joined: Sun Mar 21, 2004 5:25 pm

Post by madshi »

Why don't you use StartButton.Hide and StartButton.Show instead? Then you don't need to restart the explorer at all!
ipuiuna
Posts: 4
Joined: Sat Jun 12, 2004 3:32 pm

this solve only partial problem.

Post by ipuiuna »

madshi wrote:Why don't you use StartButton.Hide and StartButton.Show instead? Then you don't need to restart the explorer at all!
Hello Madshi, is a pleasure to talk to you.

This is the problem: I use StartButton.Close becouse with this i disable "Win" button for Start Menu with StartButton.Hide they don't disable the key.
There's others ways to do this:
1) With a hook but I don't know how do this. I try some example from Torry's Delphi TIPS but they slow down system, while I use Game for example. I need another example.
2) I can disable WIN key in registry for win 2k/XP this solve the problem and I can use in combination with the StartButton.Hide but this requires to restart Computer and only works in 2k/XP and I need compatibility to win9X.

thank's.
madshi
Site Admin
Posts: 10754
Joined: Sun Mar 21, 2004 5:25 pm

Post by madshi »

Ok, in order to close the explorer use this:

PostMessage(FindWindow('Progman', 'Program Manager'), WM_QUIT, 0, 0);

In order to restart it call ShellExecute. Or probably WinExec should also do the job.
Post Reply