<?xml version="1.0" encoding="UTF-8"?><rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:wfw="http://wellformedweb.org/CommentAPI/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	xmlns:atom="http://www.w3.org/2005/Atom"
	xmlns:sy="http://purl.org/rss/1.0/modules/syndication/"
	xmlns:slash="http://purl.org/rss/1.0/modules/slash/"
	>

<channel>
	<title>info &#8211; Uroš Vovk</title>
	<atom:link href="https://www.urosvovk.com/tag/info/feed/" rel="self" type="application/rss+xml" />
	<link>https://www.urosvovk.com</link>
	<description>Uroš Vovk home page</description>
	<lastBuildDate>Wed, 18 Jul 2018 09:10:31 +0000</lastBuildDate>
	<language>en-US</language>
	<sy:updatePeriod>
	hourly	</sy:updatePeriod>
	<sy:updateFrequency>
	1	</sy:updateFrequency>
	<generator>https://wordpress.org/?v=6.9.4</generator>
	<item>
		<title>BGInfo &#8211; Script for Local IP, Public IP and ISP Name</title>
		<link>https://www.urosvovk.com/bginfo-local-ip-public-ip-and-isp-name/</link>
					<comments>https://www.urosvovk.com/bginfo-local-ip-public-ip-and-isp-name/#comments</comments>
		
		<dc:creator><![CDATA[Uroš]]></dc:creator>
		<pubDate>Thu, 23 Feb 2017 19:00:09 +0000</pubDate>
				<category><![CDATA[Windows Stuff]]></category>
		<category><![CDATA[administration]]></category>
		<category><![CDATA[background]]></category>
		<category><![CDATA[bginfo]]></category>
		<category><![CDATA[info]]></category>
		<category><![CDATA[query]]></category>
		<category><![CDATA[script]]></category>
		<category><![CDATA[system info]]></category>
		<category><![CDATA[visual basic]]></category>
		<category><![CDATA[wallpaper]]></category>
		<category><![CDATA[windows]]></category>
		<guid isPermaLink="false">http://www.urosvovk.com/?p=788</guid>

					<description><![CDATA[I recently created 3 scripts for BGInfo &#8230; If you need it, use it ;) Local IP.vbs I found this script at ardamis.com and adapted to my needs. I removed VMware local IP, because I don&#8217;t need it strMsg = "" strComputer = "." Set objWMIService = GetObject("winmgmts:" &#038; "{impersonationLevel=impersonate}!\\" &#038; strComputer &#038; "\root\cimv2") Set IPConfigSet = &#8230; <a href="https://www.urosvovk.com/bginfo-local-ip-public-ip-and-isp-name/" class="more-link">Continue reading <span class="screen-reader-text">BGInfo &#8211; Script for Local IP, Public IP and ISP Name</span></a>]]></description>
										<content:encoded><![CDATA[<p>I recently created 3 scripts for <a href="https://technet.microsoft.com/en-us/sysinternals/bginfo.aspx">BGInfo </a>&#8230; If you need it, use it ;)</p>
<h2>Local IP.vbs</h2>
<p>I found this script at <a href="https://ardamis.com/2012/07/28/a-vbscript-for-displaying-only-ipv4-addresses-with-bginfo/" target="_blank" rel="noopener">ardamis.com</a> and adapted to my needs. I removed VMware local IP, because I don&#8217;t need it</p>
<pre lang="vb">strMsg = ""
strComputer = "."

Set objWMIService = GetObject("winmgmts:" & "{impersonationLevel=impersonate}!\\" & strComputer & "\root\cimv2")
Set IPConfigSet = objWMIService.ExecQuery("Select IPAddress,description from Win32_NetworkAdapterConfiguration WHERE IPEnabled = 'True'")

For Each IPConfig in IPConfigSet
	If Not IsNull(IPConfig.IPAddress) Then
	For i = LBound(IPConfig.IPAddress) to UBound(IPConfig.IPAddress)
		If Not Instr(IPConfig.IPAddress(i), ":") > 0 Then
			If InStr(1, IPConfig.description(i), "VMware") = 0 Then
				strMsg = strMsg & IPConfig.IPAddress(i)
				If i > 0 Then
					strMsg = strMsg & vbcrlf & VBTab
				End If
			End If
		End If
	Next
	End If
Next
Echo strMsg
</pre>
<h2>Public IP.vbs</h2>
<p>Based on script from <a href="https://www.howtogeek.com/school/sysinternals-pro/lesson7/" target="_blank" rel="noopener">howtogeek.com</a><br />
I&#8217;m retrieving my public IP from <a href="https://www.ipify.org/">ipify.org</a></p>
<pre lang="vb">Dim o
Set o = CreateObject("MSXML2.XMLHTTP")
o.open "GET", "https://api.ipify.org", False
o.send
echo o.responseText
</pre>
<h2>ISP Name.vbs</h2>
<p>I&#8217;m using <a href="https://www.whoismyisp.org">whoismyisp.org</a> for this task</p>
<pre lang="vb">Set o = CreateObject("MSXML2.XMLHTTP")
o.open "GET", "https://www.whoismyisp.org", False
o.send
strid = o.responseText
Set myRegExp = New RegExp
With myRegExp
	.Pattern = "< p class=""isp"">(.*)< / p >" 'remove spaces before use :)
	.IgnoreCase = False
	.Global = False
End With
Set myMatches = myRegExp.Execute(strid)

Echo myMatches.Item(0).SubMatches(0)
</pre>
<p><strong>IMPORTANT:</strong><br />
<span style="color: #ff0000;">Because my regex contain HTML tags I added space between < and p. If you want to use my script remove this spaces!</span></p>
]]></content:encoded>
					
					<wfw:commentRss>https://www.urosvovk.com/bginfo-local-ip-public-ip-and-isp-name/feed/</wfw:commentRss>
			<slash:comments>14</slash:comments>
		
		
			</item>
	</channel>
</rss>
