F
F
f12032018-06-08 11:01:29
PowerShell
f1203, 2018-06-08 11:01:29

How to make PowerShell see a reconnected flash drive?

If you pull out and insert the flash drive (H:\ drive) back, PowerShell stops seeing it
. Test-Path 'H:\' returns False.
Get-PSDrive -PSProvider FileSystem sees
the PS version 2 flash drive.

Answer the question

In order to leave comments, you need to log in

2 answer(s)
A
azarij, 2018-06-08
@f1203

in 5.1.17134.48 on Win10 1803 there is no such problem.
inserted flash drive:
PS C:\Users\user> test-path g:
True
pulled out flash drive:
PS C:\Users\user> test-path g:
False
inserted flash drive
PS C:\Users\user> test-path g:
True
can you update the powershell?

F
f1203, 2018-06-08
@f1203

Updated to version 5 earned

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question