Search found 78 matches

by Hackoo
23 Dec 2019 11:28
Forum: DOS Batch Forum
Topic: For /f loop findstr problem The batch script finds nothing !!!
Replies: 2
Views: 541

Re: For /f loop findstr problem The batch script finds nothing !!!

I didn't test it yet, but, Perhpas you need to add the command Pause if you execute it by double click ? for /f "skip=1 tokens=* usebackq" %%a in (`^""C:\Program Files\7-Zip\7z.exe" h -scrcsha256 "Test.7z" ^| findstr "SHA256 for data"^"`) do echo %%a pause Here is another way to get HASH into a vari...
by Hackoo
21 Dec 2019 04:37
Forum: DOS Batch Forum
Topic: tv
Replies: 4
Views: 803

Re: tv

Hi :wink: Can you please try my draft version and tell me if this script will work or not on your side ? All your comments are welcomed to improve it :lol: Thank you ! @echo off & color 0A & Mode 95,3 Title Stream IPTV Grabber by Hackoo 2019 echo( echo Type your favorite Channel Name for trying to c...
by Hackoo
19 Dec 2019 01:47
Forum: DOS Batch Forum
Topic: tv
Replies: 4
Views: 803

Re: tv

I have tested it and it worked like a charm for me :wink: :D
Thank you for this nice share bro :wink:
by Hackoo
05 Nov 2019 18:30
Forum: DOS Batch Forum
Topic: [Solved] How to filter all non-Microsoft services with WMIC and redirect the result to a text file ?
Replies: 6
Views: 3386

Re: [Solved] How to filter all non-Microsoft services with WMIC and redirect the result to a text file ?

Speaking of other scripts ... Pretty much the same thing as HTA in case no MS Office installed: <html><head><title>Non-Microsoft Services</title><meta http-equiv="content-type" content="text/html; charset=UTF-8"><meta http-equiv="x-ua-compatible" content="IE=9"> <style type="text/css"> body {font: ...
by Hackoo
01 Nov 2019 23:13
Forum: DOS Batch Forum
Topic: [Solved] How to filter all non-Microsoft services with WMIC and redirect the result to a text file ?
Replies: 6
Views: 3386

Re: [Solved] How to filter all non-Microsoft services with WMIC and redirect the result to a text file ?

Hi :wink: Here is another version using vbscript in order to export the output results with Excel. Non-Microsoft-Services.vbs Option Explicit Dim objExcel,strComputer,objWMIService Dim State,colServices,x,objService,objWorksheet,objWorkbook ' Create a new and blank spreadsheet: Set objExcel = Create...
by Hackoo
31 Oct 2019 05:18
Forum: DOS Batch Forum
Topic: [Solved] How to filter all non-Microsoft services with WMIC and redirect the result to a text file ?
Replies: 6
Views: 3386

Re: How to filter all non-Microsoft services with WMIC and redirect the result to a text file ?

Sorry My bad i got it , I forgot to add the percent % in the batch file, so with a batch file works 5/5 @echo off WMIC service where "Not PathName like '%%Micro%%' AND Not PathName like '%%Windows%%'" get Name, DisplayName, PathName, Status >"%computername%.txt" Start "" "%computername%.txt" & exit ...
by Hackoo
31 Oct 2019 05:02
Forum: DOS Batch Forum
Topic: [Solved] How to filter all non-Microsoft services with WMIC and redirect the result to a text file ?
Replies: 6
Views: 3386

[Solved] How to filter all non-Microsoft services with WMIC and redirect the result to a text file ?

Hi :wink: WMIC service where "Not PathName like '%Micro%' AND Not PathName like '%Windows%'" get Name, DisplayName, PathName, Status So this command works 5/5 on the console but the problem is when I want to redirect the result to a text file, I get all the instances without any filter? while I see ...
by Hackoo
11 Oct 2019 18:25
Forum: DOS Batch Forum
Topic: date not showing
Replies: 3
Views: 5017

Re: date not showing

I recommend you using the date independently of the region day/month order, you can use "WMIC os GET LocalDateTime" as a source, since it's in ISO order: @echo off for /F "usebackq tokens=1,2 delims==" %%i in (`wmic os get LocalDateTime /VALUE 2^>NUL`) do if '.%%i.'=='.LocalDateTime.' set ldt=%%j se...
by Hackoo
05 Oct 2019 06:26
Forum: DOS Batch Forum
Topic: [Solved] How to escape special characters on InputFile with Drag and Drop ?
Replies: 5
Views: 5490

Re: How to escape special characters on InputFile with Drag and Drop ?

Exactly This & make the script down !
If i have for example a file named Key&.txt the script dosen't works !
by Hackoo
05 Oct 2019 04:30
Forum: DOS Batch Forum
Topic: [Solved] How to escape special characters on InputFile with Drag and Drop ?
Replies: 5
Views: 5490

[Solved] How to escape special characters on InputFile with Drag and Drop ?

Hi :wink: The goal of this code is to drag and drop a file onto the script and it encodes or decodes it in Base64 with Certutil Command. So my question is : "What can i do to escape special characters when a file to be encoded or decoded have them ?" Thank you ! @echo off Set "file=%~1" If "%file%"=...
by Hackoo
22 Sep 2019 07:42
Forum: DOS Batch Forum
Topic: get File Size batch script.
Replies: 2
Views: 3983

Re: get File Size batch script.

Hi :wink: Here is another code using a small vbscript to convert size to KB,MB and GB @echo off Title Get size of file or folder from a batch file by Hackoo 2019 SetLocal enabledelayedexpansion Set "MyBatchFile=%0" Set "MyFolder=%Temp%" Set "LogFile=%~dp0SizeLog.txt" If Exist "%LogFile%" Del "%LogFi...
by Hackoo
21 Sep 2019 01:29
Forum: DOS Batch Forum
Topic: get File Size batch script.
Replies: 2
Views: 3983

Re: get File Size batch script.

Hi :wink: @echo off Title Get size file from a batch file SETLOCAL enabledelayedexpansion Set "MyBatchFile=%0" Set "MyFile=C:\temp\test.txt" echo( echo This batch file !MyBatchFile! has a size of %~z0 bytes echo( for %%A in ("%MyFile%") do ( set "Size=%%~zA" echo The file "!MyFile!" has a size of !s...
by Hackoo
21 Sep 2019 00:00
Forum: DOS Batch Forum
Topic: How to search for files with file names listed in a text file (DIR)?
Replies: 1
Views: 3559

Re: How to search for files with file names listed in a text file (DIR)?

You can give a try with this batch script : @echo off Title Search and copy from file written by Hackoo on 21/09/2019 set "Source=source.txt" Set "SourceFolder=E:\Cam_Recorder" Rem You should modify this line to set your sourcefolder set "DestinationFolder=E:\MyData\backupfiles" Rem You should modif...
by Hackoo
18 Sep 2019 10:38
Forum: DOS Batch Forum
Topic: Auto Center Vbs Window
Replies: 3
Views: 3035

Re: Auto Center Vbs Window

You should take a look here :wink: