firman Posted April 7, 2004 Posted April 7, 2004 Quick question hopefully Say I have the following $OS_VERSION = @OSVERSION $SP_VERSION = @OSServicePack How could I get $TOTAL to equal them together with a SPACE inbetween So that it would be $TOTAL = Win_XP Service Pack 1 I need something like $TOTAL = ($OS_VERSION( + ($SP_VERSION) But I do not know how to write it...please help
egridley Posted April 7, 2004 Posted April 7, 2004 You can use all 3 variables, but you don't need to. Instead, you can do something like this: $FullOS = (@OSVersion & " " & @OSServicePack) MsgBox(0, "OS", $FullOS)
scriptkitty Posted April 7, 2004 Posted April 7, 2004 egridley has ir correct.To add numbers use +To concatenate strings and variables use &To do a Logic question use ANDex:1+2=3"Foo" & "Bar"="FooBar"if 1=1 AND 2=2 Then ; This is truecon·cat·e·nate ( P ) Pronunciation Key (kn-ktn-t, kn-)tr.v. con·cat·e·nat·ed, con·cat·e·nat·ing, con·cat·e·nates 1. To connect or link in a series or chain. 2. Computer Science. To arrange (strings of characters) into a chained list. AutoIt3, the MACGYVER Pocket Knife for computers.
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now