Home | Blog | Software | Reviews and Features | Forum | Help | Donate | About us
topbanner_forum
  *

avatar image

Welcome, Guest. Please login or register.
Did you miss your activation email?

Login with username, password and session length
  • August 31, 2015, 10:21:48 AM
  • Proudly celebrating 10 years online.
  • Donate now to become a lifetime supporting member of the site and get a non-expiring license key for all of our programs.
  • donate

Author Topic: DONE: "Stop Me From Closing It" - prevent easy closing of a program  (Read 33015 times)

mouser

  • First Author
  • Administrator
  • Joined in 2005
  • *****
  • Posts: 34,946
    • View Profile
    • Mouser's Software Zone on DonationCoder.com
    • Donate to Member
Sometimes i have a web page open in my browser or something, and i want to leave it open for a while (like a few hours).
but i inevitably forget and at some point end up closing the program while tidying up the desktop.

i wonder if it wouldnt be possible to have a tray based program that let me sort of "lock" and "unlock" a running program,
which would just remove its "close" button maybe (it'd be nice of the close menu was gone from taskbar right click menu too).

so i'm not looking for some high security thing, just a way to prevent casual closing in a moment of forgetfullness.

ps. this might be a stupid request  :-\

« Last Edit: February 07, 2006, 02:50:10 AM by brotherS »

skrommel

  • Fastest code in the west
  • Developer
  • Joined in 2005
  • ***
  • Posts: 886
    • View Profile
    • 1 Hour Software by skrommel
    • Donate to Member
Re: IDEA: "Stop Me From Closing It" - prevent easy closing of a program
« Reply #1 on: December 19, 2005, 02:10:06 AM »
 :) Great idea! Can't be done in AutoHotkey, i think, as it doesn't have a global message hook.

Skrommel
Please stop by my site at  1 Hour Software by skrommel  for downloads and more info.

mouser

  • First Author
  • Administrator
  • Joined in 2005
  • *****
  • Posts: 34,946
    • View Profile
    • Mouser's Software Zone on DonationCoder.com
    • Donate to Member
Re: IDEA: "Stop Me From Closing It" - prevent easy closing of a program
« Reply #2 on: December 19, 2005, 02:20:07 AM »
no idea if it can be done in ahk, but i was thinking that it might be possible to simple modify the "system menu" property of a window that would disable its clost button.. i could be wrong though.

Carol Haynes

  • Waffles for England (patent pending)
  • Global Moderator
  • Joined in 2005
  • *****
  • Posts: 7,969
    • View Profile
    • Dales Computer Services
    • Donate to Member
Re: IDEA: "Stop Me From Closing It" - prevent easy closing of a program
« Reply #3 on: December 19, 2005, 05:41:02 AM »
Not at all stupid - I need this too for exactly the same reasons. Actually it would be nice if the close icon could be changed for a padlock or something similar.

There must be a way to do this because DM2 manages to change basic window functionality in all windows.

Actually DM2 has the nice feature of locking windows down to a floating icon which could serve a similar purpose in the interim.

nudone

  • Cody's Creator
  • Columnist
  • Joined in 2005
  • ***
  • Posts: 4,117
    • View Profile
    • Read more about this member.
    • Donate to Member
Re: IDEA: "Stop Me From Closing It" - prevent easy closing of a program
« Reply #4 on: December 19, 2005, 05:55:32 AM »
i sometimes get into a close everything frenzy and then realise i've closed too much so i have to agree it's a good idea.

skrommel

  • Fastest code in the west
  • Developer
  • Joined in 2005
  • ***
  • Posts: 886
    • View Profile
    • 1 Hour Software by skrommel
    • Donate to Member
Re: IDEA: "Stop Me From Closing It" - prevent easy closing of a program
« Reply #5 on: December 19, 2005, 05:50:28 PM »
 :) Yes, removing the system menu should work, but it also removes the min and  max as well as the X. It also wouldn't catch ownerdrawn captions.

In AutoHotkey:

Code: [Select]
WinSet,Style,-0x80000,Calc
I suggest catching WM_Close in a global message hook.

Skrommel
Please stop by my site at  1 Hour Software by skrommel  for downloads and more info.

mouser

  • First Author
  • Administrator
  • Joined in 2005
  • *****
  • Posts: 34,946
    • View Profile
    • Mouser's Software Zone on DonationCoder.com
    • Donate to Member
Re: IDEA: "Stop Me From Closing It" - prevent easy closing of a program
« Reply #6 on: December 19, 2005, 05:55:01 PM »
yeah, blocking min and max would be unfortunate.

brotherS

  • Master of Good Ideas
  • Honorary Member
  • Joined in 2005
  • **
  • Posts: 2,122
    • View Profile
    • Donate to Member
Re: IDEA: "Stop Me From Closing It" - prevent easy closing of a program
« Reply #7 on: December 20, 2005, 04:55:36 AM »
Here's the/a solution: use Firefox and install the SessionSaver and undoclosetab extensions!  :Thmbsup:

Carol Haynes

  • Waffles for England (patent pending)
  • Global Moderator
  • Joined in 2005
  • *****
  • Posts: 7,969
    • View Profile
    • Dales Computer Services
    • Donate to Member
Re: IDEA: "Stop Me From Closing It" - prevent easy closing of a program
« Reply #8 on: December 20, 2005, 04:57:33 AM »
Or even use Maxthon - which gives you the option of starting up with all the tabs from the last session.

nudone

  • Cody's Creator
  • Columnist
  • Joined in 2005
  • ***
  • Posts: 4,117
    • View Profile
    • Read more about this member.
    • Donate to Member
Re: IDEA: "Stop Me From Closing It" - prevent easy closing of a program
« Reply #9 on: December 20, 2005, 05:10:03 AM »
yeah, good point about Maxthon, Carol.

brotherS

  • Master of Good Ideas
  • Honorary Member
  • Joined in 2005
  • **
  • Posts: 2,122
    • View Profile
    • Donate to Member
Re: IDEA: "Stop Me From Closing It" - prevent easy closing of a program
« Reply #10 on: December 20, 2005, 01:48:48 PM »
Or even use Maxthon - which gives you the option of starting up with all the tabs from the last session.
Exactly that is what the SessionSaver extension for Firefox does :)

Carol Haynes

  • Waffles for England (patent pending)
  • Global Moderator
  • Joined in 2005
  • *****
  • Posts: 7,969
    • View Profile
    • Dales Computer Services
    • Donate to Member
Re: IDEA: "Stop Me From Closing It" - prevent easy closing of a program
« Reply #11 on: December 20, 2005, 05:14:51 PM »
Just pointing out for those that didn't know that it is built in as standard in Maxthon.

brotherS

  • Master of Good Ideas
  • Honorary Member
  • Joined in 2005
  • **
  • Posts: 2,122
    • View Profile
    • Donate to Member
Re: IDEA: "Stop Me From Closing It" - prevent easy closing of a program
« Reply #12 on: December 21, 2005, 03:19:43 AM »
I didn't know that, but I prefer plugins/extensions anyway  :Thmbsup:

Brad

  • Participant
  • Joined in 2006
  • *
  • gravatar avatar
  • Posts: 4
    • View Profile
    • Donate to Member
Re: IDEA: "Stop Me From Closing It" - prevent easy closing of a program
« Reply #13 on: January 07, 2006, 01:19:45 AM »
I have been using ACTUAL WINDOWS MANAGER from actual tools.
Does exactly what you are asking for and reasonably priced.
http://www.actualtools.com/

Cheers

Brad

mouser

  • First Author
  • Administrator
  • Joined in 2005
  • *****
  • Posts: 34,946
    • View Profile
    • Mouser's Software Zone on DonationCoder.com
    • Donate to Member
Re: IDEA: "Stop Me From Closing It" - prevent easy closing of a program
« Reply #14 on: February 07, 2006, 02:34:46 AM »
Ethan submitted a coding snack that will do this - works very well!!! thanks Ethan!!

in fact, he has allowed us to make it available on the Coding Snacks page, with FULL SOURCE(!)
Download Dkmy (along with his other program Maomi) on the Coding Snacks page: http://www.donationc...dingSnacks/index.php


Ethan you rock!   :Thmbsup: :Thmbsup: :Thmbsup: :Thmbsup: :Thmbsup: :Thmbsup:



ps.
Brad - thanks for that link, Actual Windows Manage looks quite useful, i may give that a try also.

skrommel

  • Fastest code in the west
  • Developer
  • Joined in 2005
  • ***
  • Posts: 886
    • View Profile
    • 1 Hour Software by skrommel
    • Donate to Member
Re: DONE: "Stop Me From Closing It" - prevent easy closing of a program
« Reply #15 on: April 08, 2006, 10:10:21 PM »
 :) Here's a very late entry! I stumbled across the solution while browsing for another project.

NoClose - Disable the Close button (X) of selected windows.

Features:
- Press Ctrl+1 to Enable or Disable the Close button of the active window.
- Press Ctrl+2 to Add a rule.
- Automatic enabling and disabling of close buttons on program start and stop, and on window creation.
- Change hotkeys and automation options.



You'll find the downloads and more info at 1 Hour Software by Skrommel.

Skrommel
Please stop by my site at  1 Hour Software by skrommel  for downloads and more info.
« Last Edit: April 08, 2006, 10:48:13 PM by skrommel »

mouser

  • First Author
  • Administrator
  • Joined in 2005
  • *****
  • Posts: 34,946
    • View Profile
    • Mouser's Software Zone on DonationCoder.com
    • Donate to Member
Re: DONE: "Stop Me From Closing It" - prevent easy closing of a program
« Reply #16 on: April 08, 2006, 10:31:40 PM »
skrommel - amazing!

beautiful about box too by the way!

skrommel

  • Fastest code in the west
  • Developer
  • Joined in 2005
  • ***
  • Posts: 886
    • View Profile
    • 1 Hour Software by skrommel
    • Donate to Member
Re: DONE: "Stop Me From Closing It" - prevent easy closing of a program
« Reply #17 on: April 08, 2006, 10:44:43 PM »
 :tellme: Please make shure you've got the latest upload, there was a typo in the first one!

Skrommel
Please stop by my site at  1 Hour Software by skrommel  for downloads and more info.

mouser

  • First Author
  • Administrator
  • Joined in 2005
  • *****
  • Posts: 34,946
    • View Profile
    • Mouser's Software Zone on DonationCoder.com
    • Donate to Member
Re: DONE: "Stop Me From Closing It" - prevent easy closing of a program
« Reply #18 on: April 08, 2006, 11:18:10 PM »
while you're tweaking it, may i suggest that the menu actually says "About NoClose.."
rather than just "NoClose", which is not clear what it will do.
(same idea would hold for any other app of course).

wreckedcarzz

  • Charter Member
  • Joined in 2005
  • ***
  • Posts: 1,623
    • View Profile
    • Read more about this member.
    • Donate to Member
Re: DONE: "Stop Me From Closing It" - prevent easy closing of a program
« Reply #19 on: November 08, 2006, 06:08:48 PM »
New suggestion...
also after Ctrl+1 is pressed, the Alt+F4 combo is disabled for that app...I go insane after I do that - one window too many can be very, very bad for me.

wesnwilma

  • Participant
  • Joined in 2007
  • *
  • gravatar avatar
  • Posts: 2
    • View Profile
    • Donate to Member
Re: DONE: "Stop Me From Closing It" - prevent easy closing of a program
« Reply #20 on: June 19, 2012, 07:36:12 AM »
I am trying to use NoClose on a Win7-64 machine but have problems with the rules. The instructions say that the requirements are part of the a window title and/or the ahk_class name (either part is optional). I am having to enter the full title AND the ahk_class or it will not work. My problem is I have some program windows where the class changes each time they open so I cannot use the rules.

Am I missing something?

~Wes

skwire

  • Global Moderator
  • Joined in 2005
  • *****
  • Posts: 4,391
    • View Profile
    • Donate to Member
Re: DONE: "Stop Me From Closing It" - prevent easy closing of a program
« Reply #21 on: December 22, 2014, 02:29:29 AM »
Hi, Wes, and a very belated welcome to the DonationCoder site.   :-[

Am I missing something?

No, you weren't missing anything.  I'm not the author of the NoClose but, due to another thread regarding the same issue, I looked over the code, found the bug, and fixed it.  So, if you're still around, please feel free to try:  http://skwire.dcmemb...ommel/NoCloseMod.zip

wesnwilma

  • Participant
  • Joined in 2007
  • *
  • gravatar avatar
  • Posts: 2
    • View Profile
    • Donate to Member
Re: DONE: "Stop Me From Closing It" - prevent easy closing of a program
« Reply #22 on: December 25, 2014, 10:46:31 AM »
Hi,
I had forgotten about this post and was just using the keyboard shortcut. Thanks for the update. It works great now.
~Wes