Thank you for being a valued part of the CNET community. As of December 1, 2020, the forums are in read-only format. In early 2021, CNET Forums will no longer be available. We are grateful for the participation and advice you have provided to one another over the years.

Thanks,

CNET Support

Question

App stays open after clicking red X > Save

May 3, 2018 2:07PM PDT

hello,

when I use for example Notepad and I want to save and close the window, I first click on the red X in the top right corner (the Save as window pops up) and save the file. I expect Notepad to close after that automatically, just as it did in W7. however, it doesnt.

is this standard in W10 or is there a bug? how do I get my application to close after I click the red X (and save)?

regards,
jazz

Discussion is locked

- Collapse -
Answer
It Should Close Just Like Other Operating Systems
May 3, 2018 3:27PM PDT

Running Chkdsk has fixed quite a few of these minor glitches for me. Try running Chkdsk in "repair" mode to find any damaged files and correct them. Start by opening a command prompt as an admin. RIGHT click on the Start button, choose "Command Prompt (Admin). (Or type "Command" in the search line, then RIGHT click on the "Command Prompt" listing at the top, choose "Run as admin".) Once there, type chkdsk /f /r /x, leaving the appropriate spaces between the letters as shown, then press the Enter key. You should see a note that it can't be run till a restart is done, type "Y" for yes, then press the Enter key again. Close the command prompt and restart the computer. Chkdsk will run upon restart and will take quite a while to finish.. Don't panic when the progress bar stays at 10% for a long time. It's fairly normal and the Chkdsk process may take a couple of hours.

When it's finished, it will boot to your normal startup/lock screen and you can login normally and then see if things are working correctly again.

Hope this helps.

Grif

- Collapse -
Not sure yet
May 4, 2018 3:04AM PDT

hey Grif, thanks for your reply. i would like to try your suggestion, but i am not sure now that the command prompt gives me this message (after i typed your command):

"The type of the file system is NTFS.
Cannot lock current drive.

Chkdsk cannot run because the volume is in use by another
process. Would you like to schedule this volume to be
checked the next time the system restarts? (Y/N)"

is it still save to choose 'Y' and restart after that?

- Collapse -
Answer
I've heard of this happening.
May 3, 2018 3:51PM PDT

But the only way I could come close to replicating it was when the save failed. Notepad was kind enough to stay open so the edits weren't lost.

When this happens, always try to just do a File/Save and watch for any sign the save failed.

- Collapse -
True
May 4, 2018 3:07AM PDT

hi R. Proffitt, that indeed would be safer. but i am not looking for that.

- Collapse -
Then I have to answer
May 4, 2018 8:57AM PDT

That notepad isn't going to work for you. If the save fails, Notepad stays open. This is how I found Notepad to operate since about Windows 3.x so if you want Notepad to exit even on a failed save, you'll have to find a replacement app.

Note: Edited for grammar.

Post was last edited on May 4, 2018 9:06 AM PDT

- Collapse -
Not a failed save
May 4, 2018 12:37PM PDT

maybe i misunderstand you. it is not about a failed save. i do want notepad to save my file. but after that i want it to close automatically, just as it does in W7 and before.

here's what i do (at work we still work with W7 and it works perfect): i open a new notepad and type my text. then i click on the red X. the 'save as' window pops up. i give the file a name, find the right folder and click OK. notepad now closes (in W7). in W10 notepad remains open, it doesnt close after i saved the file this way.

- Collapse -
Just tested Notepad and
May 4, 2018 12:43PM PDT

If I open a file, edit it and click the X, notepad asks to save and then closes.

If I just run notepad, type and then click X it does ask me to save which I gave it a filename but remains open. For this behavior to change you'll have to take this back to Microsoft. The code is not open source so only they can fix that.

Once I saved the file and make another change, again I click X and it asks me to save, answer yes and it closes.

For this reason I think you'll have to battle with Microsoft or just use some other text editor. There are many fine replacements today.

- Collapse -
Maybe
May 5, 2018 1:52PM PDT

yeah, i found that out too, about editing an existing file and close > save it. then it works.
i guess you are right. if nothing works, then it is as it is...

- Collapse -
(NT) why not wordpad instead?
May 4, 2018 9:07AM PDT
- Collapse -
funny
May 4, 2018 12:46PM PDT

interesting enough, wordpad does close after red X > save! i prefer notepad, as it is text only, but i must admit it is worth trying if there's truly no workaround for the notepad closing 'issue'.
thanks for this alternative.