Windows 10: "dir" like PowerShell script for wrting to a text file

Discus and support "dir" like PowerShell script for wrting to a text file in Windows 10 Software and Apps to solve the problem; I think I must have re-re-invented a wheel, but I couldn't find such a script.I hope this will help someone lacking the search skill it's me .This is... Discussion in 'Windows 10 Software and Apps' started by noellapin, Oct 20, 2021.

  1. noellapin Win User

    "dir" like PowerShell script for wrting to a text file


    I think I must have re-re-invented a wheel, but I couldn't find such a script.I hope this will help someone lacking the search skill it's me .This is for writing to a text file, not showing in the console.So I didn't use Alignment="Right" and FormatString.dir.ps1:# sp81 has 81 spaces.$sp81 = ' '$a = Get-ChildItem -Path $args[0]ForEach $b in $a{ $width = 80 If $b.Attributes -Like '*Directory*' { $c1 = $b.FullName + '\' } Else { $c1 = $b.FullName } $c2 = $c1.Length $c3 = $sp81 + $c1 $c4 = $c3.Length $c5 =

    :)
     
    noellapin, Oct 20, 2021
    #1
Thema:

"dir" like PowerShell script for wrting to a text file

Loading...
  1. "dir" like PowerShell script for wrting to a text file - Similar Threads - dir PowerShell script

  2. sudo dir not working powershell

    in Windows 10 Gaming
    sudo dir not working powershell: in powershell when i type sudo dir its says command not found. but when i type only dir it worksdir with no sudo in front in powershell worksbut sudo dir in cmd works finefrom what i know dir is not a cmdlet of powershell...
  3. sudo dir not working powershell

    in Windows 10 Software and Apps
    sudo dir not working powershell: in powershell when i type sudo dir its says command not found. but when i type only dir it worksdir with no sudo in front in powershell worksbut sudo dir in cmd works finefrom what i know dir is not a cmdlet of powershell...
  4. "dir" like PowerShell script for wrting to a text file

    in Windows 10 Network and Sharing
    "dir" like PowerShell script for wrting to a text file: I think I must have re-re-invented a wheel, but I couldn't find such a script.I hope this will help someone lacking the search skill it's me .This is for writing to a text file, not showing in the console.So I didn't use Alignment="Right" and FormatString.dir.ps1:# sp81 has...
  5. "dir" like PowerShell script for wrting to a text file

    in Windows 10 Gaming
    "dir" like PowerShell script for wrting to a text file: I think I must have re-re-invented a wheel, but I couldn't find such a script.I hope this will help someone lacking the search skill it's me .This is for writing to a text file, not showing in the console.So I didn't use Alignment="Right" and FormatString.dir.ps1:# sp81 has...
  6. PowerShell script

    in Windows 10 Support
    PowerShell script: The code below tests a series of IPs in a txt file.The result is as follows and is written in a txt file. 19.191.12.161 - online 19.191.12.162 - offline 19.191.12.163 - offline 19.191.12.164 - offline 19.191.12.165 - offline also see the scrennshot Code: $Output= @()$GetIP =...
  7. Hashing in powershell, output to a text file.

    in Windows 10 Support
    Hashing in powershell, output to a text file.: I want to hash file with sha512 and output it to txt file, as it doesn't show in powershell, because it is too long! So code is like this. Code: get-filehash "D:\files\OS\Linux\Debian\debian-10.5.0-amd64-netinst.iso" -Algorithm SHA512 c:\test.txt It gives error code like...
  8. powershell scripts

    in AntiVirus, Firewalls and System Security
    powershell scripts: Hi, I have azure. Someone is somehow installing powershell scripts onto my computer that allows them to host my PC through P2P and UDP connections, well I think so anyway. I have only just found powershell script entry changes in my registry by accident. These criminals...
  9. powershell script

    in Windows 10 Customization
    powershell script: looking for a script to monitor for a folder, if there is a file in that folder send it as an email, once the email is sent out, confirm and then move the files to an archive folder. monitor c:\test\*.pdf No files, do not send email. Yes Files, send an email to someone at...
  10. Running PowerShell script as a batch file

    in Windows 10 Network and Sharing
    Running PowerShell script as a batch file: Can I run the Power Shell line: "C:\Windows\System32>get-appxpackage *3dbuilder* | remove-appxpackage" from a .Bat file? ***Original title: Removing bloatware***...