Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Chris Miller on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Lock desktop . . . 3

Status
Not open for further replies.

ShyFox

Programmer
Mar 22, 2003
210
ES
I found here some weeks ago a api call that could hide and show the taskbar. That's a very good resource for me but I still need something that could complete my work. Does anyone knows how to make dissapear all the desktop icons?
Why do I need this? Because I want to make a form that is located in the <<StartUp>> folder. When it shows up I want that the taskbar and all the icons from the desktop to be hidden. When I give the pasword it will release the taskbar and the icons.
Can anyone help me?
It's not urgent but I would be very happy if you could help me.
P.S. I forgot to say that I'm using a '98 system.
Regards.
 
ShyFox,

I've no idea how to do this -- hope someone else can help.

However, as an alternative, have you thought of making your VFP form completely fill the physical screen, thus hiding the taskbar and everything else? Maybe that won't meet your needs, but, if it does, you should be able to do it by setting _SCREEN.Height and .Width to appropriate values, which you can determine via SYSMETRICS().

Mike


Mike Lewis
Edinburgh, Scotland
 
ShyFox,
If this is a requirement of the environment where this application runs, then the system administrator could set up a Profile that will accomplish this. If it's just an application that &quot;takes over&quot; the system when it's run, I know that it's the first application I'd remove and find another one! I set up my desktop the way I want it, and I want access to the taskbar, just in case the the &quot;ultimate app&quot;, locks up!

Rick
 
ShyFox:

Here is a link that might interest you :
Regspanner for Windows 98 is a Windows tweaking utility which allows you to customise the way Windows works. It allows you to make changes to your system which are normally only possible by editing the Windows Registry.

The Windows Registry can be dangerous territory for the average user and it can be easy to destroy your Windows configuration if you do not know what you are doing. RegSpanner takes the effort out of doing this, by providing an easy to use tabbed user interface:





Mike Gagnon

If you want to get the best response to a question, please check out FAQ184-2483 first.
 
mgagnon
Mike, nice link, usefull indeed, but now you rised my interest. Where can I find a function that can modify the Win 98 registry, and a example as well, and do you know a link where I can find the reg reference to hide the icons or a forum where I can discuss this Win 98 registry problem in detail?

MikeLewis
Mike, I thougt of that but I'd like to look more professional. I like that the intruder to see what's over the window but can't get there, if you catch the meaning.

rgbean
I work with a Win 98 and you know that the policies are different than a Win 2000 or Win XP where the profiles doesn't share the desktop and the settings. I surely like to have My profile and the Guest profile. If you know somethhing that I don't know please tell me.

Regards
 
ShyFox
Mike, nice link, usefull indeed, but now you rised my interest. Where can I find a function that can modify the Win 98 registry, and a example as well, and do you know a link where I can find the reg reference to hide the icons or a forum where I can discuss this Win 98 registry problem in detail?

Although VFP has some samples of editing the registry, I wouldn't recommend it. But maybe Forum615 (Windows 95/98) might be better to answer that question. Although untested, since all the incons on your desktop are &quot;LNK&quot; files, and most systems, the desktop is located at c:\windows\desktop, you could create a new directory and create an array of the files on your desktop, and move them to the other directory on startup and put them back on shutdown. Although there is the possibility of crashes...Or use Windows Logon, and create a new user, and empty that desktop, and logon with that username when it comes time to use the application.


Mike Gagnon

If you want to get the best response to a question, please check out FAQ184-2483 first.
 
Hey, check out what I just &quot;accidentally&quot; discovered. The following will make VFP8 take over the entire desktop, even covering up the taskbar. We are doing a touchscreen app that will be in a public place as a &quot;kiosk&quot; - we don't want anyone being able to get to the desktop either:

Try this:
SET SYSMENU OFF
_screen.WindowState = WINDOWSTATE_MAXIMIZED
_screen.TitleBar= 0
_screen.BorderStyle = 0
SET STATUS BAR OFF
 

ShyFox

Don't go through registry, it could be dangerous. You can hide it with few API's call. This is how you do it (tested under W2K)

--------------------
Declare Long FindWindow in User32 String cClass, String cTitle
Declare Long ShowWindow in User32 Long nhWnd, Integer nCmd

nhWnd = FindWindow('Progman', Null)
If (nhWnd != 0)
Wait 'Press any key to hide & show desktop icon' window
_Screen.WindowState = 1
= inkey(0.2, 'HM')
ShowWindow(nhWnd, 0) && Hide Desktop Icon
= inkey(1.5, 'HM')

ShowWindow(nhWnd, 5) && Show Desktop Icon
= inkey(1, 'HM')
_Screen.WindowState = 2
endif

Clear Dlls
Clear all
---------------------

Regards


-- AirCon --
 
AirCon (IS/IT--Manageme)
THANKYOU!!!!!!!!!!!!!!!
God ... a star from me ... I've searched it for the past 2 months. I thought it was forgoten.
Regards

As I go deeper the road seems to go further. We're just simply pasangers on the road of knowledge.
 
You're welcome ShyFox. Thanks for the star :)


-- AirCon --
 
Correction to my post, you need to do the maximize last:

SET SYSMENU OFF
_screen.TitleBar= 0
_screen.BorderStyle = 0
SET STATUS BAR OFF
_screen.WindowState = WINDOWSTATE_MAXIMIZED

This is awesome as there will be no keyboard available so they can't hit Alt+tab or Windows key, etc. We're creating our own virtual keyboard for the touchscreen using - so, hopefully, no c5 errors will occur causing the desktop to be seen. If we run into that, I think we'll be figuring out how to lock down windows more ourselves. {g}
 
rjean (Programmer)
You made me courios with these virtual keys.
I've been looking for a long time: How can I trap the windows keys (left and right)?
Must I declare them somewhere?
Regards

As I go deeper the road seems to go further. We're just simply pasangers on the road of knowledge.
 
Hey,

Ive got a Microtouch screen,

Im running a VB application i wrote on it,

I can lock the desktop etc, to the public,

But how do i unlock or exit the application when i want to use the desktop?

I heard that there is a way of setting up your touchscreen or code so that the user has to touch 2 or 3 corners of the application, in a certain order, to close the application!

Thanks in advance,

Agent009
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top