- Original Message -
Some powershell fragments…
Machine On line?
test-connection $computername -erroraction silentlyContinue -count 1
Last reboot…
$LastBoot=[System.Management.ManagementDateTimeConverter]::ToDateTime((Get-WmiObject
win32_operatingsystem -ComputerName $com
$addr = '0-24.254.16.172.in-addr.arpa' -split '\.',2
Then $addr[1] contains the meat.
On Oct 4, 2016, at 12:05 PM, Chris Muster wrote:
TrimStart() removes characters from the start of a string, so when you pass
‘0-24.’, you’re actually telling it to remove the characters ‘0’, ‘-‘, ‘2’,
‘4’,
Can you run the msiexec from a command prompt?
I'm not an msiexec giant, but as written (and ignoring 'smart' quotes using
only the straight ones) - assuming it's running from C:\temp, the msiexec
command line would expanded as (for the 32 bit one):
msiexec /i "C:\temp\SSEP_12.1.4013.4013_
The last person to touch the file isn't normally recorded. You'll need to
turn file auditing on (now there's a can of worms!)
From: listsad...@lists.myitforum.com [mailto:listsad...@lists.myitforum.com]
On Behalf Of Heaton, Joseph@Wildlife
Sent: Thursday, January 23, 2014 8:41 am
To: 'scripting
There is a KIX function called "SPLIT" which will let you parse the IP
address into its 4 octet components.
$mysubnetList = Split ($myaddress,".")
The second octet would be $mysubnetList[1] (array indexes start at
0).
From: listsad...@lists.myitforum.com [mailto:listsad...@li
Substr.. Substring traditionally takes a start and length parameter and
extracts the portion of a string.
If the ip address is 192.168.x.x, then the substr grabs the 2nd octet. The
starting position is a char position (the first char is at position 1. in
.NET the first char is at position 0).
We've had to do this, but the time window was measured in hours - admin
access required for the afternoon to allow installation of some software or
something like that. We had to rely on obfuscation - eg bury the sched task
deep inside the scheduled tasks tree under an unlikely name.
Still, a