Quantcast
Channel: Windows PowerShell forum
Viewing all articles
Browse latest Browse all 21975

Concatenate strings and variables

$
0
0

simple concatenation

$a = "ThisIsA"

echo "=======" + $a + "======="

gives me

+

========

+

ThisIsA

I want    ========ThisIsA========

I tried several forms of the join operator.  I tried taking out the +.  I tried replacing

the + with commas.    They all give me pretty much the same thing:  at least 3 lines of output.

I'm looking for one.     This has got to be easy.  I suppose it could be that I have been testing with v1.0 rather than 2.0, but I suspect not.

Solutions would be much appreciated.  I've searched the heck out of the internet with no success.


Viewing all articles
Browse latest Browse all 21975

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>