Search found 143 matches

by DOSadnie
18 Feb 2024 03:39
Forum: DOS Batch Forum
Topic: Move flashing prompt sign away from left edge of PowerShell window
Replies: 7
Views: 22268

Re: Move flashing prompt sign away from left edge of PowerShell window

I made basic tests files with just prompt $S$S$S$P$G Read-Host function prompt { "$(' ' * 3)$(Get-Location)> " } Read-Host function prompt { Write-Host (" " * 3) -NoNewline return " $($executionContext.SessionState.Path.CurrentLocation)$('>' * ($nestedPromptLevel + 1)) " } Read-Host but they all wer...
by DOSadnie
11 Feb 2024 04:43
Forum: DOS Batch Forum
Topic: Deleting from a Recycle Bin folder all items except certain file formats
Replies: 13
Views: 17087

Re: Deleting from a Recycle Bin folder all items except certain file formats

I made some progress [...] But it also unnecessarily goes through every item in the folder where this BAT is residing - and spits out for every one of them info [...] I finally managed do take care of that - and on top of it also hid the The system cannot find the drive specified. messages showing ...
by DOSadnie
20 Jan 2024 03:51
Forum: DOS Batch Forum
Topic: Putting BAT on Taskbar or inserting it to Tray
Replies: 4
Views: 8204

Re: Putting BAT on Taskbar or inserting it to Tray

DOSadnie wrote:
11 Aug 2023 02:44
[...]
How about moving it to the Tray area? Does any one have ideas on how to do it?
Any ideas about how to insert a script into the Tray and make it stay there as an always accessible icon?
by DOSadnie
29 Dec 2023 11:01
Forum: DOS Batch Forum
Topic: Deleting from a Recycle Bin folder all items except certain file formats
Replies: 13
Views: 17087

Re: Deleting from a Recycle Bin folder all items except certain file formats

Wow indeed, as apparently you have never ever accidentally deleted something and also never run out of disk space - thus never had to empty the Recycle Bin and never realized after some time that a re-worked item is missing. Wow

Or you just do not understand what last resort means
by DOSadnie
28 Dec 2023 07:16
Forum: DOS Batch Forum
Topic: Deleting from a Recycle Bin folder all items except certain file formats
Replies: 13
Views: 17087

Re: Deleting from a Recycle Bin folder all items except certain file formats

So does anyone know how to do this?

And also how make this latest version of ny script to apply itself also to the last volume present in the system, as apparently it ignores my volume W [which is my last]


I tried writing a corresponding PS1 script but failed miserably at it
by DOSadnie
28 Dec 2023 03:24
Forum: DOS Batch Forum
Topic: Move flashing prompt sign away from left edge of PowerShell window
Replies: 7
Views: 22268

Re: Move flashing prompt sign away from left edge of PowerShell window

DOSadnie wrote:
18 Nov 2023 11:45
If you mean replacing line
[...]
Well, did you?
by DOSadnie
09 Dec 2023 10:24
Forum: DOS Batch Forum
Topic: Timeout with GUI adjustments breaks its design after first second passes
Replies: 16
Views: 63764

Re: Timeout with GUI adjustments breaks its design after first second passes

Why you didn't tested my solution as I wrote it (more than one month ago)? As I have just now tested this once more: that code @echo off cls echo/ echo Info about what the script will do echo/ setlocal EnableDelayedExpansion rem Get an ASCII CR (13) character for /F %%a in ('copy /Z "%~F0" NUL') do...
by DOSadnie
09 Dec 2023 09:27
Forum: DOS Batch Forum
Topic: The timeout command blocks the W key from closing CMD window
Replies: 3
Views: 17075

Re: The timeout command blocks the W key from closing CMD window

How could this be happening It's obviously a bug in the code [...] Feel free to reach out to Microsoft [...] I am unable to do so because when trying to create Microsoft Account nothing happens after I enter the verification code from an e-mail I receive [i.e. there is no next step to be chosen / d...
by DOSadnie
18 Nov 2023 11:45
Forum: DOS Batch Forum
Topic: Move flashing prompt sign away from left edge of PowerShell window
Replies: 7
Views: 22268

Re: Move flashing prompt sign away from left edge of PowerShell window

If you mean replacing line

Code: Select all

$Prompt = " " * 2 + " "
with either

Code: Select all

$Prompt = "$S$S$P$G"
$Prompt = $S$S$P$G
$Prompt $S$S$P$G
then this does not work
by DOSadnie
18 Nov 2023 11:27
Forum: DOS Batch Forum
Topic: How to interrupt script by closing the CMD window with any key?
Replies: 7
Views: 27666

Re: How to interrupt script by closing the CMD window with any key?

DOSadnie wrote:
13 Oct 2023 08:49
[...]
does not make the CMD window succumb to pressing of >>w<<
I have just made a new topic about this >>W<< issue:
viewtopic.php?f=3&t=10945
by DOSadnie
18 Nov 2023 11:26
Forum: DOS Batch Forum
Topic: The timeout command blocks the W key from closing CMD window
Replies: 3
Views: 17075

The timeout command blocks the W key from closing CMD window

As pointed out in this discussion https://www.dostips.com/forum/viewtopic.php?f=3&t=10897&p=69149#p69008 apparently the timeout command makes it impossible to press any key to close CMD window, because the W is exempted from that rule. Here is basic example @echo off echo Pressing of any key will cl...
by DOSadnie
18 Nov 2023 11:12
Forum: DOS Batch Forum
Topic: Timeout with GUI adjustments breaks its design after first second passes
Replies: 16
Views: 63764

Re: Timeout with GUI adjustments breaks its design after first second passes

I have managed to produce Info about what the script will do Executing in: 3 2 1 The script has been executed [Press any key to close this CMD window] with this version @echo off cls echo/ echo Info about what the script will do echo/ setlocal EnableDelayedExpansion set "countdown=3" echo Executing ...
by DOSadnie
22 Oct 2023 09:14
Forum: DOS Batch Forum
Topic: Batch File To Create Folder With Current Date
Replies: 14
Views: 34367

Re: Batch File To Create Folder With Current Date

You might want also to take a look at this topic: viewtopic.php?f=3&t=10491
by DOSadnie
22 Oct 2023 09:10
Forum: DOS Batch Forum
Topic: Is it worth learning Powershell?
Replies: 10
Views: 36168

Re: Is it worth learning Powershell?

OM3 wrote:
20 Oct 2023 06:47
I've always stuck to DOS for small things I need to get done.
[...]
Me too; and I just a small time code tweaker. But time after time it turns out that BAT scripting is insufficient
by DOSadnie
22 Oct 2023 09:07
Forum: DOS Batch Forum
Topic: .lnk shortcut - create programatically
Replies: 5
Views: 19794

Re: .lnk shortcut - create programatically

[...] FWIW: MS is telling us that they are about to get rid of VBScript while I've not seen anything about similar intentions for JScript yet. At least I'm not aware of. What do they gain? And why would they make it impossible to run VBS scripts, when BAT scripting has not been ditched long time af...