PowerShell で reg 式のファイル パス/フォルダー構造を検証する必要があります。以下に例を示します。
c:\\scan\document\(*)
c:\\scan\document\word.doc
\\share\network\(*)
\\share\network\note.txt
注: フォルダー パスとファイルの拡張子も検証する必要があります。助けてください。
^(?:[a-zA-Z]\:|\\\\[\w\.]+\\[\w.$]+)\\(?:[\w]+\\)*\w([\w.])+$