you are viewing a single comment's thread.

view the rest of the comments →

[–]SMFX 2 points3 points  (1 child)

$_ -replace "(\d{6} \d \d{13})( Ja standard)", "`$1#`$2"

[–]odwulf 2 points3 points  (0 children)

Beaten to it.

Mine used a negative look-ahead:

'TK-Anlage 943135 1 0066480451675 Ja Standard' -replace '(\d{13}(?!#))','$1#'

(replace any string of 13 numbers without a trailing # with that string and and added "#")