Search found 397 matches

by miskox
25 Dec 2019 12:25
Forum: DOS Batch Forum
Topic: CONVERTCP.exe - Convert text from one code page to another
Replies: 130
Views: 122278

Re: CONVERTCP.exe - Convert text from one code page to another

Steffen: thanks again for all the updates. If required you can remove the XP support (I will use the latest version supported by XP (as mentioned I only need CP852 <-> CP1250 conversion)).

As it looked like for a simple project...

Saso
by miskox
13 Nov 2019 10:49
Forum: DOS Batch Forum
Topic: Determine if laptop is running on AC or battery
Replies: 7
Views: 3803

Re: Determine if laptop is running on AC or battery

Your first solution works great on laptop. Sorry for a false alarm.

Thanks.

Saso
by miskox
11 Nov 2019 04:30
Forum: DOS Batch Forum
Topic: Determine if laptop is running on AC or battery
Replies: 7
Views: 3803

Re: Determine if laptop is running on AC or battery

Sorry for a late reply. You might be right! I was running it on a desktop computer. I will try that on a laptop computer. I use XP on that machine but WMIC works.

I will let you know about the results.

Thanks.
Saso
by miskox
11 Nov 2019 04:29
Forum: DOS Batch Forum
Topic: Play a sound (.wav) file, without opening an application
Replies: 4
Views: 3545

Re: Play a sound (.wav) file, without opening an application

You could ECHO BEL (0x07) (or many of them).

Saso
by miskox
08 Nov 2019 10:25
Forum: DOS Batch Forum
Topic: Determine if laptop is running on AC or battery
Replies: 7
Views: 3803

Re: Determine if laptop is running on AC or battery

Thank Steffen! I get ERROR. WMIC does not work. Error I get: ERROR: Description = Not found Is this helpful: https://devblogs.microsoft.com/scripting/powertip-use-powershell-to-determine-if-a-laptop-is-running-on-battery/ or this: https://devblogs.microsoft.com/scripting/using-windows-powershell-to-...
by miskox
08 Nov 2019 06:14
Forum: DOS Batch Forum
Topic: Determine if laptop is running on AC or battery
Replies: 7
Views: 3803

Determine if laptop is running on AC or battery

This topic https://www.dostips.com/forum/viewtopic.php?f=3&t=9345#p60689 could be useful. I would like to know if a laptop is running on AC or on battery. Just a few days ago I was doing some work on my laptop when electricity was interrupted (for 2+ hours) because main power line 110kV was damaged ...
by miskox
15 May 2019 03:29
Forum: DOS Batch Forum
Topic: Preparation before concatenation
Replies: 7
Views: 3687

Re: Preparation before concatenation

If file format allows this then you could use

Code: Select all

copy *.m3u* new_file.m3u
Saso
by miskox
14 Apr 2019 07:00
Forum: DOS Batch Forum
Topic: NEED HELP WITH CHESS TOURNMENT FILES
Replies: 3
Views: 2623

Re: NEED HELP WITH CHESS TOURNMENT FILES

Though OP should reply, here is a link to wiki with some info regarding PGN file format: https://en.wikipedia.org/wiki/Portable_Game_Notation

Saso
by miskox
22 Mar 2019 02:42
Forum: DOS Batch Forum
Topic: CONVERTCP.exe - Convert text from one code page to another
Replies: 130
Views: 122278

Re: CONVERTCP.exe - Convert text from one code page to another

What was at first a 'simple' problem for me (converting .txt files between CP852 and CP1250 -see https://www.dostips.com/forum/viewtopic.php?p=50289#p50289) is now an ongoing project. Steffen once wrote I don't expect to get bug reports because the utility will not be found and used that often. How ...
by miskox
12 Feb 2019 06:29
Forum: DOS Batch Forum
Topic: findstr /C:""" file.txt&&set found=1 FAILS
Replies: 6
Views: 4986

Re: findstr /C:""" file.txt&&set found=1 FAILS

Great! Thanks. I added extra quote (total of 4) but that didn't work either. I had problems with findstr /C:"^|" file.txt returns no matches, while findstr /C:"|" file.txt returns a match (or more). This does not work: findstr /C:"^"" file.txt But this (your version - first quote escaped) works: fin...
by miskox
12 Feb 2019 02:59
Forum: DOS Batch Forum
Topic: findstr /C:""" file.txt&&set found=1 FAILS
Replies: 6
Views: 4986

findstr /C:""" file.txt&&set found=1 FAILS

Hello! I have .txt file: file.txt Some text Some more text with " quote This works: findstr /C:""" file.txt This fails: findstr /C:""" file.txt&&set found=1 returns: c:\findstr /C:""" file.txt&&set found=1 FINDSTR: Cannot open file.txt&&set FINDSTR: Cannot open found=1 If I want to redirect output t...
by miskox
31 Jan 2019 01:14
Forum: DOS Batch Forum
Topic: Syntax error
Replies: 3
Views: 2279

Re: Syntax error

Try with this:

change

Code: Select all

If "%_WinVer%==Windows 10" (
to

Code: Select all

If "%_WinVer%"=="Windows 10" (
Correct everywhere.

Saso
by miskox
16 Oct 2018 04:55
Forum: DOS Batch Forum
Topic: Deactivate admin privileges
Replies: 2
Views: 2156

Re: Deactivate admin privileges

Is scheduled task a solution?

Maybe you can create a scheduled task, run it and then delete it when it is done?

Saso