Anyone good with powershell want to try helping to troubleshoot a long single line command?


hsehestedt

Well-known member
Guru
VIP
Local time
1:47 PM
Posts
5,149
Location
Texas, USA
OS
Win11 Pro 25H2 (RTM+)
I have a command that I am trying to develop that I will call from within a batch file.

I have a large part of this working. Here is what currently works:

powershell.exe -executionpolicy bypass -command "Get-Disk | Get-Partition | Where-Object { $_.PartitionNumber -eq 1 -and $_.mbrtype -eq '0x0c' } | Set-Partition -mbrtype '0x1c'; Get-Disk | Get-Partition | Where-Object { $_.PartitionNumber -eq 2 -and $_.mbrtype -eq '0x07' } | Set-Partition -mbrtype '0x17'"

This command will look at the first 2 partitions on each drive. If the first partition has an MBR type of 0x0c (a FAT32 MBR partition) it will change the partition type ID to 0x1c, making it hidden.

The same thing is repeated for the second partition, changing the type from 0x07 (an NTFS MBR partition) to 0x17, again, making it hidden.

For safety, I want to add one thing to this command: I want it to look for a file called VOL1_M_MEDIA.WIM or VOL2_M_MEDIA.WIM on the root of the partitions and only change the type if those files are present.

Here is what I have tried, but this is not working. The command completes with no failure, but the type is not being changed even though the expected files are present.

powershell.exe -executionpolicy bypass -command "Get-Disk | Get-Partition | Where-Object { $_.PartitionNumber -eq 1 -and $_.mbrtype -eq '0x0c' -and (test-path '$($_.uniqueid)\\VOL1_M_MEDIA.WIM') } | Set-Partition -mbrtype '0x1c'; Get-Disk | Get-Partition | Where-Object { $_.PartitionNumber -eq 2 -and $_.mbrtype -eq '0x07' -and (test-path '$($_.uniqueid)\\VOL2_M_MEDIA.WIM') } | Set-Partition -mbrtype '0x17'"

NOTE: I need the command to find the specified files without using a drive letter.
 

My Computers My Computers

  • At a glance

    Win11 Pro 25H2 (RTM+)Intel i7-14650HX32 GBNo GPU - Built-in Intel Graphics
    OS
    Win11 Pro 25H2 (RTM+)
    Computer type
    PC/Desktop
    Manufacturer/Model
    Acemagic
    CPU
    Intel i7-14650HX
    Memory
    32 GB
    Graphics Card(s)
    No GPU - Built-in Intel Graphics
    Sound Card
    Integrated
    Monitor(s) Displays
    Varies as machine will often be moved to locations with different monitors
    Screen Resolution
    Varies
    Hard Drives
    1 x 1TB Gen 4 NVMe SSD
    PSU
    120W Power Brick
    Keyboard
    Corsair K70 Max RGB Magnetic Keyboard
    Mouse
    Logitech MX Master 3
    Internet Speed
    1Gb Up / 1 Gb Down
    Browser
    Edge
    Antivirus
    Windows Defender
  • At a glance

    Win11 Pro 25H2 (RTM+)Intel i7-1255U16 GBIntel Iris Xe Graphics
    Operating System
    Win11 Pro 25H2 (RTM+)
    Computer type
    Laptop
    Manufacturer/Model
    Lenovo ThinkBook 13x Gen 2
    CPU
    Intel i7-1255U
    Memory
    16 GB
    Graphics card(s)
    Intel Iris Xe Graphics
    Sound Card
    Realtek® ALC3306-CG codec
    Monitor(s) Displays
    13.3-inch IPS Display
    Screen Resolution
    WQXGA (2560 x 1600)
    Hard Drives
    2 TB 4 x 4 NVMe SSD
    PSU
    USB-C / Thunderbolt 4 Power / Charging
    Keyboard
    Backlit, spill resistant keyboard
    Mouse
    Buttonless Glass Precision Touchpad
    Internet Speed
    1Gb Up / 1Gb Down
    Browser
    Edge
    Antivirus
    Windows Defender
    Other Info
    WiFi 6e / Bluetooth 5.1 / Facial Recognition / Fingerprint Sensor / ToF (Time of Flight) Human Presence Sensor
You're using single-quoted strings, which don't allow variable substitution. Switch to double-quoted strings for your Test-Paths.
 

My Computer My Computer

At a glance

Windows 11 Pro 25H212th Gen Core i7-1260P64 GB Micron PC4-25600Intel Iris Xe Graphics
OS
Windows 11 Pro 25H2
Computer type
PC/Desktop
Manufacturer/Model
Intel NUC12WSHi7
CPU
12th Gen Core i7-1260P
Motherboard
NUC12WSBi7
Memory
64 GB Micron PC4-25600
Graphics Card(s)
Intel Iris Xe Graphics
Sound Card
on-board Realtek HD Audio
Monitor(s) Displays
Dell U3219Q
Screen Resolution
3840 x 2160
Hard Drives
Samsung SSD 990 PRO 1TB
Crucial MX500 2 TB
Antivirus
Microsoft Defender
You're using single-quoted strings, which don't allow variable substitution. Switch to double-quoted strings for your Test-Paths.
Thanks for the suggestion. Unfortunately that still does not work.
 

My Computers My Computers

  • At a glance

    Win11 Pro 25H2 (RTM+)Intel i7-14650HX32 GBNo GPU - Built-in Intel Graphics
    OS
    Win11 Pro 25H2 (RTM+)
    Computer type
    PC/Desktop
    Manufacturer/Model
    Acemagic
    CPU
    Intel i7-14650HX
    Memory
    32 GB
    Graphics Card(s)
    No GPU - Built-in Intel Graphics
    Sound Card
    Integrated
    Monitor(s) Displays
    Varies as machine will often be moved to locations with different monitors
    Screen Resolution
    Varies
    Hard Drives
    1 x 1TB Gen 4 NVMe SSD
    PSU
    120W Power Brick
    Keyboard
    Corsair K70 Max RGB Magnetic Keyboard
    Mouse
    Logitech MX Master 3
    Internet Speed
    1Gb Up / 1 Gb Down
    Browser
    Edge
    Antivirus
    Windows Defender
  • At a glance

    Win11 Pro 25H2 (RTM+)Intel i7-1255U16 GBIntel Iris Xe Graphics
    Operating System
    Win11 Pro 25H2 (RTM+)
    Computer type
    Laptop
    Manufacturer/Model
    Lenovo ThinkBook 13x Gen 2
    CPU
    Intel i7-1255U
    Memory
    16 GB
    Graphics card(s)
    Intel Iris Xe Graphics
    Sound Card
    Realtek® ALC3306-CG codec
    Monitor(s) Displays
    13.3-inch IPS Display
    Screen Resolution
    WQXGA (2560 x 1600)
    Hard Drives
    2 TB 4 x 4 NVMe SSD
    PSU
    USB-C / Thunderbolt 4 Power / Charging
    Keyboard
    Backlit, spill resistant keyboard
    Mouse
    Buttonless Glass Precision Touchpad
    Internet Speed
    1Gb Up / 1Gb Down
    Browser
    Edge
    Antivirus
    Windows Defender
    Other Info
    WiFi 6e / Bluetooth 5.1 / Facial Recognition / Fingerprint Sensor / ToF (Time of Flight) Human Presence Sensor
  1. Remove the outer double quotes around the command.
  2. Replace the curly braces '{}' with parentheses '()' in the Where-Object filters.
  3. Replace the single quotes around hexadecimal values with double quotes.
  4. Remove the unnecessary semicolon between the two commands.
After correcting the syntax, the command will look like this:

Powershell:
powershell.exe -executionpolicy bypass -command Get-Disk | Get-Partition | Where-Object { $_.PartitionNumber -eq 1 -and $_.mbrtype -eq "0x0c" } | Set-Partition -mbrtype "0x1c"; Get-Disk | Get-Partition | Where-Object { $_.PartitionNumber -eq 2 -and $_.mbrtype -eq "0x07" } | Set-Partition -mbrtype "0x17"
 

My Computer My Computer

At a glance

Windows 1111th Gen Intel(R) Core(TM) i7-1185G7 @ 3.00GHz16GBIntel(R) Iris(R) Xe Graphics
OS
Windows 11
Computer type
Laptop
Manufacturer/Model
Surface Laptop 4
CPU
11th Gen Intel(R) Core(TM) i7-1185G7 @ 3.00GHz
Motherboard
Laptop
Memory
16GB
Graphics Card(s)
Intel(R) Iris(R) Xe Graphics
Sound Card
Laptop
Monitor(s) Displays
Dell U3011
Screen Resolution
2560x1600
Hard Drives
Disk 0 (C:)

KBG40ZNS256G BG4A KIOXIA

Capacity: 239 GB
Formatted: 239 GB
System disk: Yes
Page file: Yes
Type: SSD

Read speed 16.5 KB/s
Write speed 132 KB/s
Active time 1%
Average response time 1.8 ms
PSU
Laptop
Case
Laptop
Cooling
Laptop
Keyboard
HP Wired
Mouse
Logitech MX Anywhere 2
Internet Speed
https://www.speedtest.net/result/14554611114
Browser
Edge
Antivirus
Sophos
Does the Test-Path part even work, on its own? Looking at my system, that wouldn't make a valid path. I would use a value from the AccessPaths property. Just a sample to look for a text file; change the name to your WIM, and I think you'll find the UniqueID property does not form a valid path.

File path formats on Windows systems

Powershell:
Get-Disk | Get-Partition |
Where-Object { $_.mbrtype -eq 0x07 } |
ForEach-Object {
    "$($_.uniqueid)\testfile.txt"
    Test-Path -LiteralPath "$($_.uniqueid)\testfile.txt"
    $_.AccessPaths | Where-Object { $_ -match "^\\\\\?\\" } |
     ForEach-Object { 
        "$($_)testfile.txt"
        Test-Path -LiteralPath "$($_)testfile.txt"
     }
}
 
Last edited:

My Computer My Computer

At a glance

Windows 11 Pro 25H212th Gen Core i7-1260P64 GB Micron PC4-25600Intel Iris Xe Graphics
OS
Windows 11 Pro 25H2
Computer type
PC/Desktop
Manufacturer/Model
Intel NUC12WSHi7
CPU
12th Gen Core i7-1260P
Motherboard
NUC12WSBi7
Memory
64 GB Micron PC4-25600
Graphics Card(s)
Intel Iris Xe Graphics
Sound Card
on-board Realtek HD Audio
Monitor(s) Displays
Dell U3219Q
Screen Resolution
3840 x 2160
Hard Drives
Samsung SSD 990 PRO 1TB
Crucial MX500 2 TB
Antivirus
Microsoft Defender
Update: I figured out a better way.

1. There's no possible way to shorten this solution to fit a single PS command line, especially if you're checking for mounted files.

2. "Get-Disk | Get-Partition" is redundant. Get-Partition returns the same results.

3. You do need a drive letter. While searching for matching partitions, it's possible that your volume is already mounted with a drive letter, or it's unassigned. The first task is to find an unused drive letter, and mount $_.AccessPaths[0] if it's not a drive letter. After checking for the file, the volume can be unmounted.
 

Attachments

Last edited:

My Computer My Computer

At a glance

Windows 7
OS
Windows 7
Thanks all for your comments. I won't get a chance to play with this more until this evening, but we'll see where we end up then.
 

My Computers My Computers

  • At a glance

    Win11 Pro 25H2 (RTM+)Intel i7-14650HX32 GBNo GPU - Built-in Intel Graphics
    OS
    Win11 Pro 25H2 (RTM+)
    Computer type
    PC/Desktop
    Manufacturer/Model
    Acemagic
    CPU
    Intel i7-14650HX
    Memory
    32 GB
    Graphics Card(s)
    No GPU - Built-in Intel Graphics
    Sound Card
    Integrated
    Monitor(s) Displays
    Varies as machine will often be moved to locations with different monitors
    Screen Resolution
    Varies
    Hard Drives
    1 x 1TB Gen 4 NVMe SSD
    PSU
    120W Power Brick
    Keyboard
    Corsair K70 Max RGB Magnetic Keyboard
    Mouse
    Logitech MX Master 3
    Internet Speed
    1Gb Up / 1 Gb Down
    Browser
    Edge
    Antivirus
    Windows Defender
  • At a glance

    Win11 Pro 25H2 (RTM+)Intel i7-1255U16 GBIntel Iris Xe Graphics
    Operating System
    Win11 Pro 25H2 (RTM+)
    Computer type
    Laptop
    Manufacturer/Model
    Lenovo ThinkBook 13x Gen 2
    CPU
    Intel i7-1255U
    Memory
    16 GB
    Graphics card(s)
    Intel Iris Xe Graphics
    Sound Card
    Realtek® ALC3306-CG codec
    Monitor(s) Displays
    13.3-inch IPS Display
    Screen Resolution
    WQXGA (2560 x 1600)
    Hard Drives
    2 TB 4 x 4 NVMe SSD
    PSU
    USB-C / Thunderbolt 4 Power / Charging
    Keyboard
    Backlit, spill resistant keyboard
    Mouse
    Buttonless Glass Precision Touchpad
    Internet Speed
    1Gb Up / 1Gb Down
    Browser
    Edge
    Antivirus
    Windows Defender
    Other Info
    WiFi 6e / Bluetooth 5.1 / Facial Recognition / Fingerprint Sensor / ToF (Time of Flight) Human Presence Sensor
Just a little comment… you do not need a drive letter. I specifically did not use one in my sample. The DOS device paths work just fine.

example from the MS article I linked:
\\.\Volume{b75e2c83-0000-0000-0000-602f00000000}\Test\Foo.txt
 

My Computer My Computer

At a glance

Windows 11 Pro 25H212th Gen Core i7-1260P64 GB Micron PC4-25600Intel Iris Xe Graphics
OS
Windows 11 Pro 25H2
Computer type
PC/Desktop
Manufacturer/Model
Intel NUC12WSHi7
CPU
12th Gen Core i7-1260P
Motherboard
NUC12WSBi7
Memory
64 GB Micron PC4-25600
Graphics Card(s)
Intel Iris Xe Graphics
Sound Card
on-board Realtek HD Audio
Monitor(s) Displays
Dell U3219Q
Screen Resolution
3840 x 2160
Hard Drives
Samsung SSD 990 PRO 1TB
Crucial MX500 2 TB
Antivirus
Microsoft Defender
After seeing @pseymour's advice, I managed to rework this into an one-liner. This still works if you have a drive letter assigned to either partition.

Original PS script:
Code:
Get-Disk | Where-Object { $_.PartitionStyle -eq 'MBR' } | ForEach-Object {
    $Part = Get-Partition -DiskNumber $_.DiskNumber -PartitionNumber 1
    if ($Part.MbrType -eq 0x0c -and (Test-Path -LiteralPath "$($Part.AccessPaths[-1])\VOL1_M_MEDIA.WIM")) {
        $Part | Set-Partition -MbrType 0x1c
    }

    $Part = Get-Partition -DiskNumber $_.DiskNumber -PartitionNumber 2
    if ($Part.MbrType -eq 0x07 -and (Test-Path -LiteralPath "$($Part.AccessPaths[-1])\VOL2_M_MEDIA.WIM")) {
        $Part | Set-Partition -MbrType 0x17
    }
 }

CMD one-liner:
Code:
powershell "Get-Disk | where {$_.PartitionStyle -eq 'MBR'} | foreach {$Part = Get-Partition -DiskNumber $_.DiskNumber -PartitionNumber 1; if ($Part.MbrType -eq 0x0c -and (Test-Path -LiteralPath """"$($Part.AccessPaths[-1])\VOL1_M_MEDIA.WIM"""")) {$Part | Set-Partition -MbrType 0x1c}; $Part = Get-Partition -DiskNumber $_.DiskNumber -PartitionNumber 2; if ($Part.MbrType -eq 0x07 -and (Test-Path -LiteralPath """"$($Part.AccessPaths[-1])\VOL2_M_MEDIA.WIM"""")) {$Part | Set-Partition -MbrType 0x17}}"
 

My Computer My Computer

At a glance

Windows 7
OS
Windows 7
Powershell:
Get-Disk |Get-Partition |? {"$($_.PartitionNumber) $($_.MbrType)" -in @('1 12','2 7')} |% {$p=$_;$_.AccessPaths |? {$_ -match '^\\\\\?\\Volume{'} |% {if (Test-Path -Path "$($_)VOL$($p.PartitionNumber)_M_MEDIA.WIM") {$m=$p.MbrType+16;Set-Partition -InputObject $p -MbrType $m}}}
 

My Computers My Computers

  • At a glance

    11 Homei7 13650HX16GB DDR5GeForce RTX 4060 Mobile
    OS
    11 Home
    Computer type
    Laptop
    Manufacturer/Model
    Asus TUF Gaming F16 (2024)
    CPU
    i7 13650HX
    Memory
    16GB DDR5
    Graphics Card(s)
    GeForce RTX 4060 Mobile
    Sound Card
    Eastern Electric MiniMax DAC Supreme; Emotiva UMC-200; Astell & Kern AK240
    Monitor(s) Displays
    Sony Bravia XR-55X90J
    Screen Resolution
    3840×2160
    Hard Drives
    512GB SSD internal
    37TB external
    PSU
    Li-ion
    Cooling
    2× Arc Flow Fans, 4× exhaust vents, 5× heatpipes
    Keyboard
    Logitech K800
    Mouse
    Logitech G402
    Internet Speed
    30Mbit/s up, 500Mbit/s down
    Browser
    FF
    Antivirus
    What's an antivirus?
  • At a glance

    11 Homei5 1135G716GB DDR4Intel Iris Xe
    Operating System
    11 Home
    Computer type
    Laptop
    Manufacturer/Model
    Medion S15450
    CPU
    i5 1135G7
    Memory
    16GB DDR4
    Graphics card(s)
    Intel Iris Xe
    Sound Card
    Eastern Electric MiniMax DAC Supreme; Emotiva UMC-200; Astell & Kern AK240
    Monitor(s) Displays
    Sony Bravia XR-55X90J
    Screen Resolution
    3840×2160
    Hard Drives
    2TB SSD internal
    37TB external
    PSU
    Li-ion
    Keyboard
    Logitech K800
    Mouse
    Logitech G402
    Internet Speed
    30Mbit/s up, 500Mbit/s down
    Browser
    FF
Have you considered rewriting the entire script in PowerShell? That would eliminate the need to construct one-liners.
 

My Computer My Computer

At a glance

Windows 10/11
OS
Windows 10/11
Computer type
Laptop
Manufacturer/Model
Acer
Hannes,

Another way to avoid long, difficult-to-debug one-liners yet stay within your preferred scripting method is to echo each conventionally-laid-out line {such as is illustrated by garlin above} to a ps1 file then run that file.

I do it all the time in my batch files.
I echo commands into .vbs files then run the vbs
e.g.
:: Announcement Set VBSScript="%TEMP%\%RANDOM%-WakeMonitor.vbs" Echo WScript.CreateObject("WScript.Shell").SendKeys "{F14}">%VBSScript% If %Completed% EQU 0 Echo CreateObject("SAPI.SPVoice").Speak "It's taking a bit longer than usual, but it should be ready soon.">>%VBSScript% If %Completed% EQU 1 Echo CreateObject("SAPI.SPVoice").Speak "Transfer completed">>%VBSScript% If %Completed% GTR 0 Echo CreateObject("SAPI.SPVoice").Speak "You can disconnect the bleedin thing now">>%VBSScript% Call %VBSScript% del %VBSScript%
And if I'm trying something new that does not behave as I expected, both the batch file creating the vbs and the vbs itself are decently laid out and can readily be debugged.

Your only significant difference would be that your Call line would be something like
Call PowerShell.exe %PSScript%
to avoid merely displaying the PS1 in a Notepad window.



All the best,
Denis
 
Last edited:

My Computer My Computer

At a glance

Windows 11 Home x64 Version 25H2 Build 26200....
OS
Windows 11 Home x64 Version 25H2 Build 26200.8037
I'm not even gonna attempt to assist here coz i have no idea what's going on but I'm quite curious to see how it finally turns out and works 😁
 

My Computers My Computers

  • At a glance

    Windows 11 Pro 22631.3810/Windows 11 RP 24H2 VMIntel Celeron N4000 @ 1.10GHz Gemini Lake 14nm8GB RamIntel UHD Graphics 600 (Lenovo)
    OS
    Windows 11 Pro 22631.3810/Windows 11 RP 24H2 VM
    Computer type
    Laptop
    Manufacturer/Model
    Lenovo
    CPU
    Intel Celeron N4000 @ 1.10GHz Gemini Lake 14nm
    Motherboard
    LENOVO LNVNB161216 (U3E1)
    Memory
    8GB Ram
    Graphics Card(s)
    Intel UHD Graphics 600 (Lenovo)
    Sound Card
    Realtek High Definition Audio Intel Display Audio
    Monitor(s) Displays
    Generic PnP Monitor (1920x1080@60Hz)
    Screen Resolution
    1920x1080
    Hard Drives
    512GB Western Digital WDC PC SN530 SDBPMPZ-512G-1101 (Unknown (SSD))
    Keyboard
    Laptop Keyboard
    Mouse
    G5 Gaming Mouse
    Internet Speed
    50mbps/50mbps
    Browser
    Chrome/Edge
    Antivirus
    Microsoft Defender
  • At a glance

    Windows 11 RP 24H2 VMIntel Celeron N4000 @ 1.10GHz Gemini Lake 14nm8GB RamIntel UHD Graphics 600 (Lenovo)
    Operating System
    Windows 11 RP 24H2 VM
    Computer type
    Laptop
    Manufacturer/Model
    Lenovo
    CPU
    Intel Celeron N4000 @ 1.10GHz Gemini Lake 14nm
    Motherboard
    LENOVO LNVNB161216 (U3E1)
    Memory
    8GB Ram
    Graphics card(s)
    Intel UHD Graphics 600 (Lenovo)
    Sound Card
    Realtek High Definition Audio Intel Display Audio
    Monitor(s) Displays
    Generic PnP Monitor (1920x1080@60Hz)
    Screen Resolution
    1920x1080
    Keyboard
    Laptop Keyboard
    Mouse
    G5 Gaming Mouse
    Internet Speed
    50mbps/50mbps
    Browser
    Chrome/Edge
    Antivirus
    Microsoft Defender
Another way to avoid long, difficult-to-debug one-liners yet stay within your preferred scripting method is to echo each conventionally-laid-out line {such as is illustrated by garlin above} to a ps1 file then run that file.

Indeed that works, but it's ugly, adds complication (writing and executing a temp file), is more work to maintain, and doesn't play well with code-highlighting editors.

As a long time batch file writer, and someone that resisted PowerShell for a long time, I can say it's worth making the change. With ChatGPT's help, converting to PowerShell is much easier than it used to be.
 

My Computer My Computer

At a glance

Windows 10/11
OS
Windows 10/11
Computer type
Laptop
Manufacturer/Model
Acer
Thanks for all the advice. I still need to play with this, but in experimenting, I'm having more difficulties.

I want to run some of these commands in Windows PE. I have prepped Windows PE by adding powershell components into Windows PE. I can run Windows PE commands but get no output, not even an error message. For example, if I issue a "Get-Disk" I get no visible output at all.
 

My Computers My Computers

  • At a glance

    Win11 Pro 25H2 (RTM+)Intel i7-14650HX32 GBNo GPU - Built-in Intel Graphics
    OS
    Win11 Pro 25H2 (RTM+)
    Computer type
    PC/Desktop
    Manufacturer/Model
    Acemagic
    CPU
    Intel i7-14650HX
    Memory
    32 GB
    Graphics Card(s)
    No GPU - Built-in Intel Graphics
    Sound Card
    Integrated
    Monitor(s) Displays
    Varies as machine will often be moved to locations with different monitors
    Screen Resolution
    Varies
    Hard Drives
    1 x 1TB Gen 4 NVMe SSD
    PSU
    120W Power Brick
    Keyboard
    Corsair K70 Max RGB Magnetic Keyboard
    Mouse
    Logitech MX Master 3
    Internet Speed
    1Gb Up / 1 Gb Down
    Browser
    Edge
    Antivirus
    Windows Defender
  • At a glance

    Win11 Pro 25H2 (RTM+)Intel i7-1255U16 GBIntel Iris Xe Graphics
    Operating System
    Win11 Pro 25H2 (RTM+)
    Computer type
    Laptop
    Manufacturer/Model
    Lenovo ThinkBook 13x Gen 2
    CPU
    Intel i7-1255U
    Memory
    16 GB
    Graphics card(s)
    Intel Iris Xe Graphics
    Sound Card
    Realtek® ALC3306-CG codec
    Monitor(s) Displays
    13.3-inch IPS Display
    Screen Resolution
    WQXGA (2560 x 1600)
    Hard Drives
    2 TB 4 x 4 NVMe SSD
    PSU
    USB-C / Thunderbolt 4 Power / Charging
    Keyboard
    Backlit, spill resistant keyboard
    Mouse
    Buttonless Glass Precision Touchpad
    Internet Speed
    1Gb Up / 1Gb Down
    Browser
    Edge
    Antivirus
    Windows Defender
    Other Info
    WiFi 6e / Bluetooth 5.1 / Facial Recognition / Fingerprint Sensor / ToF (Time of Flight) Human Presence Sensor
Thanks for all the advice. I still need to play with this, but in experimenting, I'm having more difficulties.

I want to run some of these commands in Windows PE. I have prepped Windows PE by adding powershell components into Windows PE. I can run Windows PE commands but get no output, not even an error message. For example, if I issue a "Get-Disk" I get no visible output at all.
Was this the guide you followed?

 

My Computer My Computer

At a glance

Windows 10/11
OS
Windows 10/11
Computer type
Laptop
Manufacturer/Model
Acer

My Computers My Computers

  • At a glance

    Win11 Pro 25H2 (RTM+)Intel i7-14650HX32 GBNo GPU - Built-in Intel Graphics
    OS
    Win11 Pro 25H2 (RTM+)
    Computer type
    PC/Desktop
    Manufacturer/Model
    Acemagic
    CPU
    Intel i7-14650HX
    Memory
    32 GB
    Graphics Card(s)
    No GPU - Built-in Intel Graphics
    Sound Card
    Integrated
    Monitor(s) Displays
    Varies as machine will often be moved to locations with different monitors
    Screen Resolution
    Varies
    Hard Drives
    1 x 1TB Gen 4 NVMe SSD
    PSU
    120W Power Brick
    Keyboard
    Corsair K70 Max RGB Magnetic Keyboard
    Mouse
    Logitech MX Master 3
    Internet Speed
    1Gb Up / 1 Gb Down
    Browser
    Edge
    Antivirus
    Windows Defender
  • At a glance

    Win11 Pro 25H2 (RTM+)Intel i7-1255U16 GBIntel Iris Xe Graphics
    Operating System
    Win11 Pro 25H2 (RTM+)
    Computer type
    Laptop
    Manufacturer/Model
    Lenovo ThinkBook 13x Gen 2
    CPU
    Intel i7-1255U
    Memory
    16 GB
    Graphics card(s)
    Intel Iris Xe Graphics
    Sound Card
    Realtek® ALC3306-CG codec
    Monitor(s) Displays
    13.3-inch IPS Display
    Screen Resolution
    WQXGA (2560 x 1600)
    Hard Drives
    2 TB 4 x 4 NVMe SSD
    PSU
    USB-C / Thunderbolt 4 Power / Charging
    Keyboard
    Backlit, spill resistant keyboard
    Mouse
    Buttonless Glass Precision Touchpad
    Internet Speed
    1Gb Up / 1Gb Down
    Browser
    Edge
    Antivirus
    Windows Defender
    Other Info
    WiFi 6e / Bluetooth 5.1 / Facial Recognition / Fingerprint Sensor / ToF (Time of Flight) Human Presence Sensor

Latest Support Threads

Back
Top Bottom