Sep 16, 2014 #1 TheKidd IS-IT--Management Joined May 17, 2000 Messages 167 Location US thread1619-1715904 You can use Code: $myEmailExt="@efaxsend.com" $myFiles=Split-Path "C:\staging\*.pdf" -Leaf -Resolve foreach ($myFile in $myFiles) { $myFile=$myFile.Remove(10) $myEmailAddr="$myFile$myEmailExt" $myEmailAddr }
thread1619-1715904 You can use Code: $myEmailExt="@efaxsend.com" $myFiles=Split-Path "C:\staging\*.pdf" -Leaf -Resolve foreach ($myFile in $myFiles) { $myFile=$myFile.Remove(10) $myEmailAddr="$myFile$myEmailExt" $myEmailAddr }
Sep 17, 2014 #2 strongm MIS Joined May 24, 2001 Messages 20,264 Location GB I expect in the last year or so that the OP may have already found a solution ... Upvote 0 Downvote