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 Westi on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Disable Closing Windows with top right "X" 1

Status
Not open for further replies.

PCSMITHS

IS-IT--Management
May 7, 2007
13
US
Any way to disable closing the Window (using the "X") that the DOS FPD2.6a is running in?
 
Run it in full screen mode and no "X" shows.
Alt-Enter toggles between window and full screen but your users may not know this
 
I run 2 to 3 different programs, do not want to run in full screen, + when run in full sreen I can not remotely access computer with VNC.
 
Thanks Dave, thats is what I am look for, a way to disable it. I have users that close the fp programs using the windows "x" and it leaves tmp files on the network.
 
You can avoid tmp files being left on the network by adding
TMPFILES=c:\mytmpdir in CONFIG.FP which will make the files unique to each user on their local workstation.

You can issue a DOS command to erase all .tmp files at startup without conflicting with other users.
 
TMPFILES can not contain a path, only a drive letter, but
SORTWORK, PROGWORK, ... can.


Tomas
 
I currently am running a cleanup with a del *.tmp command, I want to prevent them from being left by preventing user the ability to close the window with the "x".
 

You could run the DOS session full screen and ALT+TAB between windows. Have you tried searching Google?
 
I need two windows open to view both at same time, full screen is not an option, Yes, I have searched Google.
Please only respond if you can help with disabling the "x" on the window screen.
 

I realise that my suggestion will not help with disabling the close button, but then no-one else's has yet either so it looks as though a workaround (or user training) is the best you can hope for.
 
Olaf,
I am using FPD2.6a DOS, I know of no Form.Closable=.F. in it nor do I known of any Form.Closable=.F. in the Registry.

I sure that Form.Closable=.F. works great in VFP. If I could just find the time to convert my 130+ DOS over to VFP9 I would be in fine shape. Known any good over all Tech/Programmers (VFP) near St. Gabriel, LA, Who is willing to work at state pay?
 
PCSMITHS

WinTopMost.exe is a shareware program that will disable the 'x' in any window (including the command prompt). You can download a trial here:


I have only tried it out and it does indeed disable the close button, but I do not know if it's suitable for your needs or if you want to pay $65 per license, and it has to be running minimised. It does, however show that it is possible to disable the close button, so you might find out how to do it.

Best of luck
Roger
 
It is a trial with a "heckler", I have over 130 programs so it would have to be run against each of the shortcuts, I did not see anything in the registry that gave a clue of how it works, but it did work, I can not see spending $8500 to do this.
 
Thanks Tomas,

This did the trick.

Care to share the source code?

Jim
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top